in reply to Perl Fool needs help
#!/usr/local/bin/perl open INFILE, "<myInfile.txt" or die "cannot open myInfile.txt $!\n"; open OUTFILE, ">myOutfile.txt" or die "cannot open myOutfile.txt $!\n" +; while ( <INFILE> ) { if ( /^address/ ) { chomp; my ($tag, $value) = split(/=/, $_); print OUTFILE $value, "\n"; } } close INFILE; close OUTFILE;
|
|---|