<[EMAIL PROTECTED]> wrote:
> <[EMAIL PROTECTED]> wrote:
>
>> Hi all,
>>
>> My scripts, which are running perfectly well on a Win2000 webserver, do not
>> function correctly under MacOS X.
>>
>> The first thing I've been able to identify that is malfunctioning is the
>> standard file reading process I've always used:
>>
>> while(<FILE>){
>> push (@array,$_);
>> }
>>
>> print $array[1]; ##prints the second line of file
>>
>> For some reason MacOS X reads the entire file in to $array[0] the first time
>> round, instead of putting one line per array element.
>>
>> Has anybody else had this problem?
>
> [localhost:~] tor% perl -e 'while(<>){push(@array,$_)} print "\$array\[1\]:
> $array[1]";'
Forget this, the problem is probably the line-endings used in the file.
:)
Tor