• Hi,

    I have wordpress installed as part of my website http://www.merket.org (It’s Noel’s Weblog). What I’m trying to do is get it to put the five most recent posts and an exerpt from each on that homepage. I just migrated to wordpress from Moveable Type and in MT I just created a new template page which I php included in the main page to accomplish this. I know WordPress has similar functinoality, it just seems different and more complicated to me. Would it be best to get some kind of RSS aggregator to accomplish this or is it possible to do this with a template and how would that be done?

    Thank you for your help.

Viewing 1 replies (of 1 total)
  • So is the blog that you want to post content from just on that same domain, perhaps something further into the site (merket.org/blog or something)? And you want content from that blog on the home page? No problem. Here it is:

    Even if a file is outside the directory of your WordPress install, require('pathtoyourwordpressinstall/wp-config.php'); at the top of a page means that you can use any WordPress functions on that page. You’ll just need to be sure to type out the path to your WordPress files instead of ./ in anything. Here’s what I have to call up my WordPress blog home page from outside the WordPress directory:
    <?php
    require('pathtoyourwordpressinstall/wp-config.php');
    define('WP_USE_THEMES', true);
    require('pathtoyourwordpressinstall/wp-blog-header.php');
    ?>

    Here’s a WordPress RSS solution for this on a pastebin page.

    Posting lengthy code is a serious hassle here! Any links in the code, whether I use CODE tags or backticks, are rendered as actual hyperlinks and not just HTML. Where should I post this complaint/problem/bug about this post.

Viewing 1 replies (of 1 total)
  • The topic ‘Listing recent posts on website home page’ is closed to new replies.