method
textilize_without_paragraph
v2.1.0 -
Show latest stable
- Class:
ActionView::Helpers::TextHelper
textilize_without_paragraph(text)public
Returns the text with all the Textile codes turned into HTML tags, but without the bounding <p> tag that RedCloth adds.
You can learn more about Textile’s syntax at its website. This method is only available if RedCloth is available.
Examples
textilize_without_paragraph("*This is Textile!* Rejoice!") # => "<strong>This is Textile!</strong> Rejoice!" textilize_without_paragraph("I _love_ ROR(Ruby on Rails)!") # => "I <em>love</em> <acronym title="Ruby on Rails">ROR</acronym>!" textilize_without_paragraph("h2. Textile makes markup -easy- simple!") # => "<h2>Textile makes markup <del>easy</del> simple!</h2>" textilize_without_paragraph("Visit the Rails website "here":http://www.rubyonrails.org/.) # => "Visit the Rails website <a href="http://www.rubyonrails.org/">here</a>."
1Note
New Website for RedCloth
The Link above doesnt work anymore. This one should be the new one: http://redcloth.org/