Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine

Re: file reading issues

by mojobozo (Monk)
on Aug 03, 2005 at 19:17 UTC ( #480605=note: print w/ replies, xml ) Need Help??

in reply to file reading issues

Follow up question: How can I strip off the leading blank spaces on each line? Keep in mind that I'm using jdporter's snipit of code for grabbing between the comments. I like to indent my html for readability (mine) but don't need all those spaces in the form.

word (wrd)
interj. Slang. Used to express approval or an affirmative response to
something. Sometimes used with up. Source

Comment on Re: file reading issues
Replies are listed 'Best First'.
Re^2: file reading issues
by kwaping (Priest) on Aug 03, 2005 at 19:39 UTC
    Using jdporter's code:
    while (<FILENAME>) { last if /<!-- Begin -->/; } while (<FILENAME>) { last if /<!-- End -->/; s/^\s*//; #<- new line here print ; }

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (3)
As of 2015-11-29 00:49 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (746 votes), past polls