Let wpautop()
do the work:
echo wpautop( get_post_meta($post->ID, $my_field, true) );
wpautop()
will detect leading block elements and use <p>
only when the value starts with a string.
Let wpautop()
do the work:
echo wpautop( get_post_meta($post->ID, $my_field, true) );
wpautop()
will detect leading block elements and use <p>
only when the value starts with a string.