first-> search("^(Contact|m):
.*(a)(192\.168\.|10\.|172\.16)")
second-> search("(From|f):.*@foo.bar")
The string is a regular expression. You can find out more about them
online (eg:
http://sitescooper.org/tao_regexps.html ), or by typing
man 7 regex
at the command line.
"(Contact|m)" means 'either the word "Contact" or the word
"m"'.
A caret ^ at the beginning of the regular expression means "only match
if the following string is at the beginning of the line" -- so the first
expression would match
Contact: che.sosa(a)192.168.0.1
but would not match
I wish to Contact: che.sosa(a)192.168.0.1
Have fun,
Paul
--
P-a-u-l- -J-a-n-k-o-w-s-k-i paul(a)teragen.com.au
"A programmer," he said with obvious amazement, is the sort of person
"who
drinks Coke in the morning." -- Boston Globe article on The High Tech Set