Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: How to retrieve the string after the space???

by DentArthurDent (Monk)
on Sep 07, 2006 at 16:07 UTC ( #571725=note: print w/ replies, xml ) Need Help??


in reply to How to retrieve the string after the space???

TIMTOWTDI!

if ($line =~ m/To:/i) { ($header,$to) = split(/ /,$line); print "To is: $to\n"; }
The split function splits the line apart into an array in this case by spaces. Note that this could cause you pain if your addresses contain spaces!
----
My mission: To boldy split infinitives that have never been split before!

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://571725]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (8)
As of 2016-07-25 17:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What is your favorite alternate name for a (specific) keyboard key?


















    Results (225 votes). Check out past polls.