• My excerpts shows on the blog page, but it doesn’t show on the template-homepage.php. I’ve added this to my functions.php:

    function wpcodex_add_excerpt_support_for_pages() {
    	add_post_type_support( 'page', 'excerpt' );
    }
    add_action( 'init', 'wpcodex_add_excerpt_support_for_pages' );

    But no excerpt. I also have “Summary” selected for my Reading options in the settings. What I could I add to make this possible?

Viewing 1 replies (of 1 total)
  • Your code only changes the editor (giving you a place to write an excerpt).
    The Settings > Reading option is for the RSS feed, which is not handled by the theme.

    If the template-homepage.php file does not call the_excerpt() then you won’t see any excerpts.

Viewing 1 replies (of 1 total)

The topic ‘Adding Excerpt to Custom Page Template’ is closed to new replies.