Home › Forums › Backend Issues (wp-admin) › Using Custom Shortcodes in ACF Fields › Reply To: Using Custom Shortcodes in ACF Fields
Hi @ste9890
I think that the way to solve this depends on how your ACF fields are being used..
If they are exclusively for shortcodes you can use the do_shortcode()
function to output the information like this:
echo do_shortcode(get_field('myfield'));
If they can contain a regular textstring as well as shortcodes you could propably make use of the_content filter:
echo apply_filters('the_content', get_field('myfield'));
Please note that this will also apply p tags around regular strings.
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.