You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have some html that is rendered through the rails rendering pipeline, and ends up with properly escaped special characters. Sadly, when this goes inside premailer, it comes out unescaped.
I.e.
given a string with quotes like Rosy O' Donnel
which ie escaped through the standard ERB utiles or rails' stuff to become "Rosy O' Donnel"
when I pass it through premailer like Premailer.new(escaped, with_html_string: true).to_inline_css
I expect: <!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\" \"http://www.w3.org/TR/REC-html40/loose.dtd\">\n" + "<html><body><p>Rosy O%#39 Donnel</p></body></html>\n
but I am getting: "<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\" \"http://www.w3.org/TR/REC-html40/loose.dtd\">\n" + "<html><body><p>Rosy O' Donnel</p></body></html>\n"
The same happens with ".
Is this expected? Other stuff like & or < is left alone.
The text was updated successfully, but these errors were encountered:
I have some html that is rendered through the rails rendering pipeline, and ends up with properly escaped special characters. Sadly, when this goes inside premailer, it comes out unescaped.
I.e.
given a string with quotes like
Rosy O' Donnel
which ie escaped through the standard ERB utiles or rails' stuff to become
"Rosy O' Donnel"
when I pass it through premailer like
Premailer.new(escaped, with_html_string: true).to_inline_css
I expect:
<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\" \"http://www.w3.org/TR/REC-html40/loose.dtd\">\n" + "<html><body><p>Rosy O%#39 Donnel</p></body></html>\n
but I am getting:
"<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\" \"http://www.w3.org/TR/REC-html40/loose.dtd\">\n" + "<html><body><p>Rosy O' Donnel</p></body></html>\n"
The same happens with
"
.Is this expected? Other stuff like
&
or<
is left alone.The text was updated successfully, but these errors were encountered: