Skip to:
Content
Pages
Categories
Search
Top
Bottom

RSS Feed Issues

  • Hey guys,

    I’m currently putting together my first site using WordPress % bbPress (they are both linked etc).

    What i’m trying to do is display the 4 most recent active threads. By this, i do not mean the last 5 posts. I mean the latest 5 threads that have posts made in them. I hope that makes sense.

    E.g.

    [Thread Title] by [Original Poster]

    I came across a script which links my bbPress RSS feed to my WordPress custom template, here it is:

    <?php if(function_exists('fetch_feed')) {
    include_once(ABSPATH.WPINC.'/feed.php');
    $feed = fetch_feed('http://localhost/wordpress/bbpress/rss.php?forum=1');
    $limit = $feed->get_item_quantity(4);
    $items = $feed->get_items(0, $limit);
    }
    if ($limit == 0) echo '';
    else foreach ($items as $item) : ?>

    <ul class="latest">

    <li>

    <span class="title"><?php echo $item->get_title(); ?></span>

    </li>

    <?php endforeach; ?>

    I tried linking to “http://localhost/wordpress/bbpress/rss” etc but “http://localhost/wordpress/bbpress/rss.php?forum=1″ was the only feed i could pick up. It doesn’t really matter though considering i’ll only have the single forum section anyway.

    Now, this produces the following on my WordPress template:

    Tigeran on “Your first topic”

    [Last Post Author] on [Thread Title]

    As stated before, i want it to appear like this:

    [Thread Title] by [Original Poster]

    I soon found out that i needed to edit the rss2.php file located in bbpressbb-templateskakumei folder as i’m using this template. Looking through it i came across this:

    <title><?php post_author(); ?> <?php _e('on')?> "<?php topic_title( $bb_post->topic_id ); ?>"</title>

    & changed it to this:

    <title><?php topic_title( $bb_post->topic_id ); ?> <?php _e('by')?> <?php post_author(); ?></title>

    But there is no change as it stays as the original. It’s like i cannot overwrite this file. Any help would be greatly appreciated.

    Thanks.

You must be logged in to reply to this topic.