Just fiddling with regex's because I see them in the digests everyday, and 
I though the best way to learn these is to try them.
Currently sliding backwards down the learning curve...

Just want to parse an email header containing addresses in format:

 >>   Joe Frderick Blogss <[EMAIL PROTECTED]>,
(repeated hundreds of times...)

and I want to write a script that will give me an output of

Name, [EMAIL PROTECTED]

I probably don't need regexes to do this but I thought I'd try and see what 
I learn
So I'm suing the s/// function to first match the email address with the 
following regex (snaffled of a website somewhere):
^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*$

So this will match the email part, but I want it to find '<email>' and 
return  'email'.
How does the stupid s/// function work !!! The perldoc pages keep using a 
$& to refer to and manipulate the input string but I don't know how to 
delete within the string , i.e. the <> characters.

Is this so hard because I'm trying to row with a fork or what ?


Michael Carmody
MDU, Public Health Lab
Dept. of Microbiology and Immunology
The University of Melbourne, Parkville


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to