Disable WP from removing unique html tags for schema
-
I am trying to add in schema markup to my wp pages, which involve things like: <div itemscope itemtype=”https://schema.org/Event”>
<div itemprop=”name”>Name</div>
<span itemprop=”description”>asdf</span>..But these are always removed by WP after I save. I have tried to:
1) add functions in functions.php w/ things like
“remove_filter( ‘the_content’, ‘wpautop’ );”
“remove_filter( ‘wp_replace_in_html_tags’ );”2) add in the custom tags I need into the kses.php file in the “$allowedposttags” array, with no luck.
I think I have tried a few different ways to figure this out, but every time I try to add the tag’s I mentioned they are removed :/
Many thanks in advance ??
- The topic ‘Disable WP from removing unique html tags for schema’ is closed to new replies.