Tiny MCE not adding p tag when saving theme option

If you want the contents of an option, variables, or anything for that matter to be treated like post content you’ll need to call the post content filters.

<?php echo apply_filters( 'the_content', $your_var ); ?>

Your data is then treated in the same way as post content is, inline with the code sample you’ve posted, the call should go like this..

<?php echo apply_filters( 'the_content', theme_option('homepage_content') ); ?>

Hope that helps. 🙂

Leave a Comment