Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Re: Record Separator affecting Regex

by jdporter (Paladin)
on Nov 07, 2002 at 19:41 UTC ( [id://211199]=note: print w/replies, xml ) Need Help??


in reply to Re: Record Separator affecting Regex
in thread Record Separator affecting Regex

Yeah, I think you have the right idea here, Bird. Better than mine, under the circumstances.

I'd probably rework it as follows, to get rid of all that extra leading whitespace:

local $/ = ";\n"; while ( <> ) { s/^#.*$//mg; # kill comments s/^\s+//; # kill all remaining leading whitespace print "Query: $_\n"; }

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (2)
As of 2024-04-26 07:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found