Support » Fixing WordPress » Having bits of the content from Pages appear on the front page

  • Resolved buskerdog

    (@buskerdog)


    I’m using WP more for CMS than for blogging and I’d like to peg my front page with clips of a few of my Pages. I found the “MORE” divider for the Page content but I’m not sure what code to put on the front page so that it displays the segments of the Page content plus a (Read More) link to the Pages themselves.

    Thanks.

Viewing 4 replies - 1 through 4 (of 4 total)
  • moshu

    (@moshu)

    It will not, normally.
    Pages are not meant to be displayed more than ONE in one page.

    buskerdog

    (@buskerdog)

    Hmmm… I feel like there’s gotta be a way with php or something to pull that text into the front page.

    If there really isn’t, maybe I should fake it some other way.

    moshu

    (@moshu)

    I didn’t say it’s impossible – what I said is WP doesn’t work like that. There is no ready-made (or simple) code to display excerpts or “before-more” portions of a WP Page. (The “more” tag doesn’t even work on Pages…)

    If you have a home.php template in your theme – a lot of things can be coded into it, either manually or with plugins.
    To get ideas… 🙂
    http://codex.wordpress.org/Template_Tags/query_posts#Parameters
    http://guff.szub.net/2005/01/27/get-a-post/

    buskerdog

    (@buskerdog)

    This seems to work. I found it in one of the links you posted:

    <?php
    query_posts(‘pagename=Your Page Name’);

    <?php the_excerpt(”); ?>
    yada yada

    so thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Having bits of the content from Pages appear on the front page’ is closed to new replies.