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
Hi, sorry if this is not the best place for questions or support, but I guess it's possible my issue is a bug.
I'm trying to use Ox to parse HTML5, and I'm finding that it is escaping < and & in attributes, text, and CDATA. I understand this is correct behavior for XML, so I set convert_special, but it doesn't have the effect I'm looking for:
When I parse this using a class passed to Ox.sax_html, text(), and cdata() are both given escaped strings, so if I try to recreate that <style> block, it will show content: ">";.
So, question is - is this correct behavior and, if so, can it be controlled and/or disabled?
The text was updated successfully, but these errors were encountered:
Looking at the code, attributes and text use the :convert_special option but CDATA does not. Can you provide the code (handler) that received the > string?
OK, in putting together a minimal example, I’m realizing the behavior is not in sax_parse, but I was also creating a document and it's that that was escaping the values, which seems reasonable and consistent with the docs. Sorry for the bother, but thanks for being responsive!
Hi, sorry if this is not the best place for questions or support, but I guess it's possible my issue is a bug.
I'm trying to use Ox to parse HTML5, and I'm finding that it is escaping
<
and&
in attributes, text, and CDATA. I understand this is correct behavior for XML, so I setconvert_special
, but it doesn't have the effect I'm looking for:When I parse this using a class passed to
Ox.sax_html
, text(), and cdata() are both given escaped strings, so if I try to recreate that<style>
block, it will showcontent: ">";
.So, question is - is this correct behavior and, if so, can it be controlled and/or disabled?
The text was updated successfully, but these errors were encountered: