The forums have permanently moved to forum.kirupa.com. This forum will be kept around in read-only mode for archival purposes. To learn how to continue using your existing account on the new forums, check out this thread.


Results 1 to 4 of 4

Thread: Calling recent posts to a webpage

  1. #1

    Calling recent posts to a webpage

    I used to know how to do this, with php how can you display recent posts to your forum on your home page?

  2. #2
    Depends on the forum software. If it's like most, it's in MySQL.

    Just do a nice SELECT * FROM `tablecontainingpostsname` ORDER BY `fieldcontainingeithertimeorid` (ASC/DESC depending on the field you're ordering by, figure it out) LIMIT 5

    5 can be changed of course.
    got pwnt?

  3. #3
    4,029
    posts
    home cooking is killing the restaurant industry
    Alternatively, if your forum provides an RSS feed, you could use a package like XML_Feed_Parser to parse and display it on your homepage.

    although presumably you'd want some sort of caching mechanism to prevent your RSS feed from being hit on every load of the page
    There are only 10 kinds of people in this world:
    Those that might know ternary, those that do, and those that don't
    Say NO to DRM.

  4. #4
    Quote Originally Posted by hl View Post
    Depends on the forum software. If it's like most, it's in MySQL.

    Just do a nice SELECT * FROM `tablecontainingpostsname` ORDER BY `fieldcontainingeithertimeorid` (ASC/DESC depending on the field you're ordering by, figure it out) LIMIT 5

    5 can be changed of course.
    All right thanks a lot.
    And no I don't have an RSS fead.
    Last edited by travis; January 1st, 2007 at 09:58 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012