html2haml -r should unescape HTML after parsing. Thanks to Michael O'Malley. Also a tiny bit of reformatting in engine.rb.
git-svn-id: svn://hamptoncatlin.com/haml/trunk@564 7063305b-7217-0410-af8c-cdc13e5119b9
This commit is contained in:
parent
cc238a740c
commit
47d757c7d4
|
@ -783,7 +783,8 @@ END
|
|||
# This means that we can render the tag directly to text and not process it in the buffer
|
||||
open_tag = prerender_tag(tag_name, atomic, attributes)
|
||||
|
||||
if tag_closed = do_one_liner && !parse
|
||||
tag_closed = do_one_liner && !parse
|
||||
if tag_closed
|
||||
open_tag += value
|
||||
open_tag += "</#{tag_name}>"
|
||||
end
|
||||
|
|
|
@ -129,7 +129,8 @@ module Haml
|
|||
def to_haml(tabs = 0)
|
||||
output = "#{tabulate(tabs)}"
|
||||
if HTML.options[:rhtml] && name[0...5] == 'haml:'
|
||||
return output + HTML.send("haml_tag_#{name[5..-1]}", self.innerHTML)
|
||||
return output + HTML.send("haml_tag_#{name[5..-1]}",
|
||||
CGI.unescapeHTML(self.innerHTML))
|
||||
end
|
||||
|
||||
output += "%#{name}" unless name == 'div' && (attributes.include?('id') || attributes.include?('class'))
|
||||
|
|
Loading…
Reference in New Issue