Hi,
I’m using a shortcode for a phone number, amongst other things, within text fields however there’s an added linebreak I cannot get rid of.
I’d like the shortcode contents to appear ‘in-line’
Edit: This appears to happen with WSIWYG and not a number field.
Is there something I need to add to functions.php to prevent this happening?
Thanks.
You should use do_shortcode().
Just wrap all your content inside this function.
change:
the_field('my_text');
to:
echo do_shortcode(get_field('my_text'));