procmail
[Top] [All Lists]

Re: Stripping HTML: Another Question

1997-10-13 10:22:42
->Hmm. My question would be: why does the version in the logs say
->"URL-MINDER====/OH!/g"? Did you edit the script you sent? I'd say that
->the shell is trying to interpret the !/g as a request to repeat the last
->command that began with !/g (and can't find it.) This script is also
->going to strip out all the email addresses in the header (which are also
->surrounded by <>.) Try this:


The "OH!" was just graffitti of sorts. The "\!" fixed things.  Thanks,
-Clint






->
->:0
->* ^Subject: your registered page.*has changed
->{
->      :0fb
->      | sed 's/<[^>]*>//g' | sed 's/--====URL-MINDER====/OH\!/g'
->
->      :0:
->      incoming/tv
->}
->
->As I said in the first message, perl is overkill for simple regex search
->and replace; sed will do the same thing with fewer resources. This
->recipie starts by checking the headers for the proper subject. Then it
->runs the body of the message through the sed processes, using the f flag
->to indicate filtering (which means that the message has not yet been
->delivered.) The next rule locks and delivers to incoming/tv.
->
->-- 
->Michael Stone, Sysadmin, ITRI     PGP: key 1024/76556F95 from mit keyserver,
->mstone(_at_)itri(_dot_)loyola(_dot_)edu            finger, or email with 
"Subject: get pgp key" 
->

-Clint

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Clint Lipinski      VaTech Computer Science Class Of '97         
clint(_at_)acm(_dot_)vt(_dot_)edu
http://www.acm.vt.edu/~clint -- My no-frames homepage              
http://www.acm.vt.edu/~clint/vcr/voices.htm -- Searchable cartoon voices 
database
http://www.acm.vt.edu/~clint/vcr -- My video library -- all my videos catalogged
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=