Site hosted by Angelfire.com: Build your free website today!
use strict; use Mac::Files; chdir(FindFolder(kOnSystemDisk, kSystemFolderType) . ':Internet Search Sites:') or die "Can't find plugin directory: $!\n"; my @files = <*.src>; foreach my $f (@files) { local $/; open(FILE, "+<$f") or die "Can't open $f: $!\n"; my $file = <FILE>; (my $new = $file) =~ s/^\s*banner(start|end)\b.*$//mgi; if ($new ne $file) { truncate(FILE, 0); seek(FILE, 0, 0); print FILE $new; $f =~ s/\.src$//; print "Killed ads in $f\n"; } close(FILE); }