CaRP Evolution Documentation
CaRP Evolution Documentation
twitter youtube linkedin google-plus
CaRP Evolution Box
Web This Site

CaRP: Caching RSS Parser - Documentation

CaRP Interactive FAQ
Getting Started: Free Download | Purchase | Install
Reference: Functions | Plugins | Themes | Full Index
Etc.: Display Formatting | Example Code | Affiliates

CarpGroupFilter( feedlist );

Store local copies of a number of newsfeeds, and filter items out of it them
This function combines CarpCache and CarpFilter the same way that CarpCacheFilter does, but performs these functions for multiple feeds with one call. It also limits the number of feeds that are refetched at once in order to avoid unacceptably slow response times when many cache files have expired.

  1. feedlist: An array with RSS feed addresses as keys, and as values, either cache file names or arrays containing a cache file name and an encoding. The addresses may be URLs, paths to a local files, or data from a Grouper cache specified as "grouper:cache-name". Note that Grouper must be loaded before calling CarpGroupFilter if using the "grouper:" syntax. See the example below for details.

Return value: Up till version 3.6.2, none. Version 3.6.3 and later: returns a list of cache file names, suitable for passing to CarpAggregate or CarpInterleave (see example code below).

Usage Example:
// create a list of RSS feeds and cache file names, and optionally an encoding
require_once '/home/geckotribe/carp/carp.php';
CarpConf('filterin','Gecko Tribe');
For CaRP versions prior to 3.6.3, replace the last two lines with the following:
// extract a list of cache file names from the feed list created above
foreach ($feeds as $v) {
	if (is_array($v)) list($v,$encoding)=$v;
// the list of cache files has an extra "|" on the beginning--use substr to remove it