View Single Post
Old Jan 25th, 2005, 5:35 PM   #4
Lance
Programmer
 
Lance's Avatar
 
Join Date: Oct 2004
Location: Chicago, IL USA
Posts: 74
Rep Power: 4 Lance is on a distinguished road
Send a message via AIM to Lance
So do a:

foreach $line (<file>) {
$line =~ s/thing to remove//g;
}

of you can open() a file, and create a new file. Print each line, from one file to another, unless that line doesn't belong there. Then you can delete the orginal file, and rename it to whatever it should be.

That's the jist of it. Unless you give me some example data to process, and what I should be removing, I can't really code anything. So you're on your own without more specifications...
__________________
/* LANCE */
C++;  /* this makes C bigger but returns the old value */
char *site = "slackwise.net",
     *home = "lance.slackwise.net",
     *pics = "flickr.com/photos/slackwise";
Lance is offline   Reply With Quote