Re: remplace ...

2001-07-09 Thread Aaron Craig
At 13:05 09.07.2001 +0200, [EMAIL PROTECTED] wrote: >Hi, > >I want to remplace all the word "html" in "php" in some web pages ... > >I tried this but nothing is happening : > >open (TRANS, "c:\\test\\test.txt"); > >@transformation=; > >foreach $ligne (@transformation) >{ >chomp($ligne); >$transfor

RE: remplace ...

2001-07-09 Thread John Edwards
Try this. Remember to save the data after you've changed it... --- $input = "c:\\test\\test.txt"; $output = "c:\\test\\out.txt"; open IN, $input or die "Can't open $input: $!"; open OUT, ">$output" or die "Can't open $output: $!"; while () { s/html/php/ig; print OUT; } close OUT