Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

13 lines (11 sloc) 0.352 kB
module Textilize
def textilize(text)
RedCloth.new(text).to_html.html_safe unless text.blank?
end
def textilize_without_paragraph(text)
textiled = textilize(text)
if textiled[0..2] == "<p>" then textiled = textiled[3..-1] end
if textiled[-4..-1] == "</p>" then textiled = textiled[0..-5] end
return textiled
end
end
Jump to Line
Something went wrong with that request. Please try again.