Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
function dispos_func( $atts ) {
$atts = shortcode_atts(
array(
'post_id' => 'no foo',
), $atts, 'DisplayPost' );
$post_id = $atts['post_id'];
return get_post_field('post_content', $post_id);
}
add_shortcode( 'DisplayPost', 'dispos_func' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment