Create a gist now

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<?php
/**
* Create new 'meta_content` filter.
*
* Recreate the default filters applied to `the_content`,
* so content retrieved using `get_post_meta` can be
* formatted in the same way.
*/
add_filter( 'meta_content', 'wptexturize' );
add_filter( 'meta_content', 'convert_smilies' );
add_filter( 'meta_content', 'convert_chars' );
add_filter( 'meta_content', 'wpautop' );
add_filter( 'meta_content', 'shortcode_unautop' );
add_filter( 'meta_content', 'prepend_attachment' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment