Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: newline substitution is removing text too

by japhy (Canon)
on Jan 21, 2007 at 04:37 UTC ( #595724=note: print w/ replies, xml ) Need Help??


in reply to newline substitution is removing text too

There are probably also carriage returns in the file as well. tr/\r//d or s/\r//g will remove them.

Jeff japhy Pinyan, P.L., P.M., P.O.D, X.S.: Perl, regex, and perl hacker
How can we ever be the sold short or the cheated, we who for every service have long ago been overpaid? ~~ Meister Eckhart

Replies are listed 'Best First'.
Re^2: newline substitution is removing text too
by Groxx (Novice) on Jan 21, 2007 at 05:35 UTC
    I just ran a /\r/ search of the file, and nothing came up. While I can see this happening, aren't those also converted to "\n" by Perl automatically, unless told to do otherwise? And even if it didn't, would they show up in other applications?

    And even then, why would it be in the middle of a line of text or HTML tag?

    Thanks for the idea, though, I hadn't thought of that possibility.

Log In?
Username:
Password:

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

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


















    Results (20 votes). Check out past polls.