Home › Forums › Add-ons › Repeater Field › WYWIWYG and the_content filter
This didn’t work for us. After entering the code in functions.php it hid everything within tab_content. Please advise, thanks.
Hi @healthfirst
Please remember that the filter ‘the_content’ shoudl only ever be run on the front end of the website.
I don’t know what ‘tab_content’ is, but it sounds like it should be in the admin.
Please use the correct filter depending on your ACF version and always debug your code to test if it is working / not working
http://www.advancedcustomfields.com/resources/how-to/debug/
Hi @healthfirst
The functions.php file is used to hook into both the front and back ends of the website to customize many parts.
the_content
is a filter which should only be used on the front end of the website. As in, shown in a page template, not shown in the wp-admin.
Can you please confirm what version of ACF you are using?
You mentioned ‘Tab_content’ is referring to the tab content (WYSIWYG) in the Admin folder.
So am I right to assume the problem in the backend (wp-admin)?
I don’t know what <?php build_i_world_map(1); ?>
is but it shouldn’t be related to this issue.
The original code should only modify the WYSIWYG value on the front end of the website (page template), but should not ever have changed the value in the backend. The backend should have had no changes from the code.
If you are running ACF v4.x.x, then this is the wrong code. Please use format_value_for_api
, not format_value
and this could explain why it is being run in the backend.
And please check your console log for any JS errors on the page. This could explain why the WYSIWYG field is no longer working
The topic ‘WYWIWYG and the_content filter’ is closed to new replies.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.