This is my situation. I have two plugins, one plugin will read a remote XML file and downloads content then it calls a function on another plugin to do the actual importing of posts to the WordPress database.
Now here is the problem, the second problem inserts posts using wp_insert_post method and this is a multisite implementation.
As a result, it strips div ids inside the post_content for example:
Someone suggests me to use force_filtered_html_on_import filters like this:
add_filter( 'force_filtered_html_on_import', '__return_false', 999 );
This will disable the filtering of HTML during import and will preserved the div ids inside the post_content.
I have tried adding this filter on the first plugin but it didn't work. I have a restriction to add this filter to the first plugin as the second plugin is beyond my control.
How to make this work by only adding this filter on the first plugin that do the import? This filter is not so documented by WordPress. I would appreciate any help on this one. Thanks.