Here's a simple code edit that will allow for paging of the feed.

It allows for paging of a feed in the fashion:

- sample.com/feedpath/feed
- sample.com/feedpath/feed/2
- sample.com/feedpath/feed/3

If you use arguments with your Views RSS feed your milage may vary.

in views_rss.views.inc

/**
* add pager
* idea taken from http://anexusit.com:8080/blog/how-enable-pagination-rss-feed-drupal-6
*/
function views_rss_views_pre_execute(&$view) {
    if($view->display[$view->current_display]->display_plugin == 'feed'){
        $view->pager['current_page'] =$view->args[0];
    }

}

Comments

maciej.zgadzaj’s picture

Status:Needs review» Closed (won't fix)

First, branch 1.x is not receiving updates anymore. Then, RSS feeds do not support paging functionality as per its spec, and I don't really see this feature being widely demanded/needed. Considering that if someone needs it, there already is a way of doing it - as described in linked blog post - I'm not going to implement it in this module.

TechNikh’s picture

Issue summary:View changes

Paging is supported in RSS as per http://tools.ietf.org/html/rfc5005#section-3

<link rel="next" href="http://example.org/index.atom?page=2"/>

relaxnow’s picture

The above code did not work for me with D7, the following did:

<?php
function MODULENAME_views_pre_build(view &$view) {
  /* @var views_display $display */
  $display = $view->display[$view->current_display];
  /* @var views_plugin_display_feed $display_handler */
  $display_handler = $display->handler;

  if (!$display_handler instanceof views_plugin_display_feed) {
    return;
  }

  $display_handler->options['use pager'] = TRUE;
  $display_handler->options['pager']['type'] = 'full';
}
?>