How come something so simple is seemingly so hard this morning.
How do I replace all carriage returns and new line characters with a
blank space? Should be straight forward no?
Your Friend,
John
–
John K.
[email protected]
How come something so simple is seemingly so hard this morning.
How do I replace all carriage returns and new line characters with a
blank space? Should be straight forward no?
Your Friend,
John
–
John K.
[email protected]
string_with_returns_and_newlines.gsub(/\r?\n/, " ") work?
RSL
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs