• puckman75

    (@puckman75)


    hi there,

    I want to truncate my posts on my home page, then have people click through to read the whole story on another page. First off, how do I do this? Secondly, should I create my posts as Pages, then just place a snippet preview of the Page on the Home page with a Post? I dont want the full Post on the homepage.

    here is my site – http://www.dronereport.net thanks for your help!

Viewing 1 replies (of 1 total)
  • You can manually set the break by adding the <!--more--> tag to your post and it will add a continue reading link to the home page. If you are using the visual editor just click the more button to add the tag or if using the “text” editor manually add <!--more--> to your post where you want the break.

    To do this pragmatically by using the_excerpt() instead of the_content(), you will need to edit your theme or create a child theme. The file you want to override with your child theme is content.php. Copy the content.php file from the twentyeleven directory and move it to your child theme root directory and change the following line (line 35 as of 3.6)

    <?php if ( is_search() ) : // Only display Excerpts for Search ?>

    Change this line to:

    <?php if ( is_search() || is_home() ) : // Only display Excerpts for Search and on Home page ?>

    This will cause the auto excerpts to display on your home page with a link to the full single post.

Viewing 1 replies (of 1 total)
  • The topic ‘Truncating Posts on Homepage’ is closed to new replies.