in reply to Re: How to get undecoded html entities with HTML::TreeBuilder
in thread How to get undecoded html entities with HTML::TreeBuilder
One - since decoding/encoding is reversible:
Unfortunately, this isn't an option. It might well be that the raw HTML contains both encoded as unencoded entities. As in the end I'll need my code to be part of an filter, I'd really need the raw, original text, in order to be able to substitute it when and how appropiate.
As to hacking the source modules - I didn't succeed, and I'm not even really sure I can accomplish that, as decoding is done by HTML::Parser in it's C-code part.
HTML::Parser offers a method to get the raw attributes - $p->attr_encoded sets a boolean flag when a new parser is built - but I didn't find yet a way to use it via HTML::TreeBuilder.
Thank you, anyway.