Re: [MacPerl-WebCGI] well split!! (Solved)

[email protected] (Adam Witney) Thu, 08 Mar 2001 11:07:56 -0500
Newsgroups perl.macperl.webcgi
Message-ID <B6CD188C.82E9%[email protected]>
> Robin:
> 
> Okay, while Bruce's solution ( local $/ = "\r";  ) worked, the above
> code didn't for me. I did:
> 
> while (<DATA>)
> {
> s/\015\012|\012|\015/\n/g;
> next if /^$/;  # skip empty lines


applying the s/// here is too late as the while loop has already read in the
whole file... 

the easiest method would be to just save the file with Unix line endings
with BBEdit before transferring it over to your Linux box.

adam