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
Hello, I am trying to add support for some additional elements (many of them HTML5) that are not supported by default. To do this, I followed the customize documentation here: http://htmlpurifier.org/docs/enduser-customize.html
However, I am seeing inconsistent results when trying to add elements in this way.
Below is an example that demonstrates my point.
I am using the latest version 4.18.0
My basic setup looks like this:
As you can see, the figure and figcaption elements are not stripped as expected. However, article is still being removed.
How am I meant to add support for this? Is something in my config incorrect?
I have also tested with other elements like input, label, header, footer, section, etc and got the same results.
Hello, I am trying to add support for some additional elements (many of them HTML5) that are not supported by default. To do this, I followed the customize documentation here: http://htmlpurifier.org/docs/enduser-customize.html
However, I am seeing inconsistent results when trying to add elements in this way.
Below is an example that demonstrates my point.
I am using the latest version
4.18.0
My basic setup looks like this:
The raw HTML I am testing with looks like:
After running this HTML through the purifier, this is what I see being returned:
As you can see, the
figure
andfigcaption
elements are not stripped as expected. However,article
is still being removed.How am I meant to add support for this? Is something in my config incorrect?
I have also tested with other elements like
input
,label
,header
,footer
,section
, etc and got the same results.Is my only option trying to use another library with more HTML5 support like https://github.com/xemlock/htmlpurifier-html5 ?
EDIT:
After further testing, I have found that this config works and does not remove the
article
element:However, I'm still confused on why it didn't work with my prior config as that is what is stated in the docs.
The text was updated successfully, but these errors were encountered: