diff options
Diffstat (limited to 'railties/guides/rails_guides/textile_extensions.rb')
-rw-r--r-- | railties/guides/rails_guides/textile_extensions.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/railties/guides/rails_guides/textile_extensions.rb b/railties/guides/rails_guides/textile_extensions.rb index 794083b44b..504b527398 100644 --- a/railties/guides/rails_guides/textile_extensions.rb +++ b/railties/guides/rails_guides/textile_extensions.rb @@ -1,5 +1,5 @@ module RailsGuides - module TextileExtensions + module TextileExtensions def notestuff(body) body.gsub!(/^(IMPORTANT|CAUTION|WARNING|NOTE|INFO)(?:\.|\:)(.*)$/) do |m| css_class = $1.downcase @@ -31,7 +31,7 @@ module RailsGuides end def code(body) - body.gsub!(%r{<(yaml|shell|ruby|erb|html|sql)>(.*?)</\1>}m) do |m| + body.gsub!(%r{<(yaml|shell|ruby|erb|html|sql|plain)>(.*?)</\1>}m) do |m| es = ERB::Util.h($2) css_class = ['erb', 'shell'].include?($1) ? 'html' : $1 %{<notextile><div class="code_container"><code class="#{css_class}">#{es}</code></div></notextile>} |