Keep html entities like é and € escaped#138
Keep html entities like é and € escaped#138jeroenvdheuvel wants to merge 1 commit intotijsverkoyen:masterfrom
é and € escaped#138Conversation
…. Before dumping the html put the replaced `&` back again.
94bdb45 to
79d875b
Compare
|
@tijsverkoyen merge conflict is resolved |
|
@tijsverkoyen could you provide comment on this issue? I'm fine with changing it if needed. When you don't like to merge it (because you don't like to feature) is okay too (but unfortunate for me). |
|
I have a small problem with this change ... 1.) if we have a html-template with "\r" (Mac) carriage return ... as a hack I replaced this chars, but I don't know if there are more magic from the xml-parser that isn't covert by our unit-tests?! |
|
I am of the opinion that this should be merged. cc @tijsverkoyen |
|
@jeroenvdheuvel I moved this logic into "https://github.com/voku/simple_html_dom", so now the Dom-Parser is separated from the CssToInline class. It looks much more cleaner and we have some extra unit-tests in the "simple_html_dom"-repository. What do you think? -> voku@b0da918 |
|
I guess the issue could be solved with html_entity_decode() to decode DomDocument::saveHtml() output |
Keep the escaped html entities as is. Instead of changing them to their ISO 8859-1 or UTF-8 counterparts
éand€.Html entities should not be touched, since not all everybody understands UTF-8 characters. By not escaping them, the user of this library stays in control.