Tony Marquis wrote:

Very simple question.

I'm reading a file and i want to remove all the <CR><LF> in each lines.

while(FIC) {

   $test = $_; #remove crlf.
   ........... some code

}

How can i do that.


Try

$test =~ s/[\r\f]//g;


to remove newlines, use

$test =~ s/[\n]//g;




--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to