PHP code to display posts on another page (2 posts)

  1. IanMcGreene
    Posted 9 years ago #

    I am wondering what the PHP code would be to display the last 4 blog posts on another page.

    I have an existing homepage which links to the WP blog, but I want the last 4 posts to be displayed on the side of the homepage, just can't figure out the code to make this happen.

    Thanks so much!

  2. moshu
    Posted 9 years ago #

    You have several options:
    1. RSS feeds and a feedreader (search)
    2. A recent_posts plugin (though it means additional hist on your mysql server)
    3. A customized Loop (with the same caveat as above)

    Lots of good info here and in the Codex: http://codex.wordpress.org/Main_Page

Topic Closed

This topic has been closed to new replies.

About this Topic