I display my custom field like this :
<p><?php echo get_post_meta($post->ID, $my_field, true); ?></p>
As long as the field contains plain text, the markup is normal :
But if I put some HTML list in it, the content jumps out of the P tags and some additional P tags are even added :
<p></p> <ul> <li>something</li> <li>something</li> </ul> <p></p>
Why is that and how to fix the problem ?