i have a filter to change the content on a plugin:


Now i am using ACF and i copied over the content from the wordpress editor to a wysiwig editor field my filter doesn't affect it anymore.

So my question is how can i modify my filter to affect my new wysiwig custom field?

I am refering to the front end not the editor itself but the content people sees on the page.

add_filter('acf_the_content', 'replace_content');
  • Some explanation would be nice
    – cjbj
    Jan 23 '17 at 16:49
  • 1
    The filter he's using just affect Wordpress' default wysiwig. To do the same on ACF's wysiwig he needs to use the filter above. Jan 23 '17 at 16:58
  • Wow this worked thanks!. Is there an easy way to affect both without duplicating the function with a different name? Jan 23 '17 at 16:59
  • 1
    You don't need to duplicate de function, just call it on both filters. Jan 23 '17 at 17:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.