Skip to content

Commit

Permalink
Apply default filters before returning
Browse files Browse the repository at this point in the history
  • Loading branch information
johnstonphilip committed Feb 20, 2020
1 parent 8a3f02f commit 729a613
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions packages/block-library/src/template-part/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,17 @@ function render_block_core_template_part( $attributes ) {
if ( is_null( $content ) ) {
return 'Template Part Not Found';
}

// Run through the actions that are typically taken on the_content.
$content = do_blocks( $content );
$content = wptexturize( $content );
$content = convert_smilies( $content );
$content = wpautop( $content );
$content = shortcode_unautop( $content );
$content = prepend_attachment( $content );
$content = wp_make_content_images_responsive( $content );
$content = do_shortcode( $content );

return str_replace( ']]>', ']]>', $content );
}

Expand Down

0 comments on commit 729a613

Please sign in to comment.