search for: clean_white_space

Displaying 1 result from an estimated 1 matches for "clean_white_space".

2006 Jun 23
0
Hardbreaks and Redcloth.
...it dosn''t do any better), even a script that handles HTML well (I.E. entities, renders broken tags as text)? After trying everything I could find without having to make yet another post about this topic I tried using gsub!("\n",<br />'') and editing: > def clean_white_space( text ) > # normalize line breaks > #text.gsub!( /\r\n/, "\n" ) > #text.gsub!( /\r/, "\n" ) > text.gsub!( /\t/, '' '' ) > text.gsub!( /^ +$/, '''' ) > #text.gsub!( /\n{3,}/, "\n\...