WordPress.org

Ready to get started?Download WordPress

Forums

Modified rss feed - how? (4 posts)

  1. sitapati
    Member
    Posted 9 years ago #

    I've been trying to figure out how to do this, or see if someone else has done it, but I have been successful in either yet.

    I want an rss feed that is in between the full one and the sparse summary. What I would like is an rss feed that basically outputs the equivalent of the front page - HTML with images, with the more tag rendered, so that I can control paging of articles in my rss feed.

    I tried to edit wp-rss2.php and substitute the the_content() call from index.php, but that just gives me a full article feed.

    Does anyone have any pointers / has anyone already done this.

    cheers,
    Sita-pati

  2. Kafkaesqui

    Posted 9 years ago #

    I don't know of any functionality provided for in the various RSS specifications for paging of content.

    It's basically a situation of providing a summary, or providing full content; trying to duplicate what you can do on your web site through RSS, I think you're going to run into a lot of problems--not just from the specs, but from visitors to your site attempting to view your feed through the numerous kinds of feed readers out there.

  3. sitapati
    Member
    Posted 9 years ago #

    Perhaps I haven't explained it nicely.

    I want the content tag of the rss feed to contain what is display on the front page of my blog. At the moment I can choose between a few sentences or the whole thing. On the front page I can control where it is truncated by using the more tag. So I want exactly that content of the front page syndicated in the feed, including or excluding the "more" hyperlink.

    This is b2evo's default behaviour. It will pass the entire article, or if the article has been paged it will pass the first part, along with the hyperlink to "Read more"

  4. Kafkaesqui

    Posted 9 years ago #

    Ah, I see what you're after now. As far as I can tell, WordPress handles rss files as something like individual posts, meaning that when syndicating full text, it outputs the content for each item as if on a single post page. Off-hand I'm not sure what it would take to modify this behavior. However, a possible workaround may be a plugin of mine I wrote for a similar problem:

    http://guff.szub.net/the-excerpt-reloaded

    If you installed this and replaced:

    <?php the_content(); ?>

    in your wp-rss2.php with my plugin's tag:

    <?php the_excerpt_reloaded(); ?>

    and set WordPress to full text for your syndication feeds, you could specify how many words to output before adding the more link, as well as define which HTML tags to allow, etc.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.