[pmwiki-users] pmwiki-2.1.beta14 released, improved RSS and Atom feeds

DaveG pmwiki at solidgone.com
Sun Dec 11 11:10:29 CST 2005


Interesting to hear that they are very different. I didn't get that from 
the RssFeedDisplay which has
 >> add the line include_once("$FarmD/local/rssdisplay.php");
 >> or include_once("local/magpie/rss_fetch.inc"); to your local/config.php

I was actually looking to cache the RSS feed generated by pmWiki, and 
thought Magpie was the answer. Reading your comments, and thinking about 
it a little more, I see that caching the AllRecentChanges is pretty 
meaningless -- it's a pretty low hit already, so caching won't make much 
difference.

I'll add some text to the RssFeedDisplay to make the difference clearer.

  ~ ~ Dave


Patrick R. Michaud wrote:
> On Sat, Dec 10, 2005 at 09:31:01PM -0500, DaveG wrote:
> 
>>In order to use Magpie (ref 
>>http://www.pmwiki.org/wiki/Cookbook/RssFeedDisplay) in conjunction with 
>>2.1b14, should I include both:
>>   require_once('local/magpierss/rss_fetch.inc');
>>AND
>>   include_once('scripts/feeds.php');
>>
>>At the moment I have both, I get xml generated on action=rss, and have 
>>the CACHE directory set. But the magpie cache does not get populated. 
>>I'm a little confussed at how Magpie and PMwiki play together, if at all.
> 
> 
> Well, the two do very different things, so they ought to be
> almost totally independent of each other and work just fine.
> 
> Magpie is used to import RSS feeds from other sites and display them
> in wiki pages.  The PmWiki web feeds system in 2.1.beta14 is intended
> to generate web feeds that can be imported by other systems.  (And yes,
> it's possible for Magpie to import a PmWiki feed, but they aren't
> have any dependencies on each other.)
> 
> So, include_once('scripts/feeds.php') simply adds ?action=rss
> and ?action=atom to your wiki, to generate RSS feeds that other
> programs can import.
> 
> The magpie recipe adds an (:RSS ...:) markup that can be used
> to display the contents of a feed in a wiki page.
> 
> So, you should be able to add either or both of the recipes to your
> site and have them work, and if the magpie cache isn't being
> populated, it's likely something strictly to do with the magpie
> setup and not anything introduced by beta14.
> 
> Hope this helps,
> 
> Pm
> 
> 
>>Patrick R. Michaud wrote:
>>
>>>I've just released pmwiki-2.1.beta14, which makes significant
>>>changes to PmWiki's built-in web feed capabilities.  The newest
>>>beta release is available from
>>>
>>>   http://www.pmwiki.org/pub/pmwiki/pmwiki-2.1.beta14.tgz
>>>   http://www.pmwiki.org/pub/pmwiki/pmwiki-2.1.beta14.zip
>>>   http://www.sourceforge.net/projects/pmwiki
>>>   svn://pmwiki.org/pmwiki/tags/latest
>>>
>>>In this new release, the scripts/rss.php file has been replaced by a
>>>newer scripts/rss.php.  Existing sites can either continue to use the
>>>traditional rss.php, or switch over to feeds.php.
>>>
>>>The new feeds.php works correctly with UTF-8 and can generate feeds
>>>in any of RSS 2.0, Atom 1.0, RSS 1.0, and even Dublin Core Metadata 
>>>format.  It can also produce feeds from any wikitrail, category, or group,
>>>and supports the use of the RSS <enclosure> tag for podcasting.
>>>
>>>To generate feeds, add a line like the following to a local configuration
>>>file:
>>>
>>>   if ($action == 'rss') include_once('scripts/feeds.php');
>>>   if ($action == 'atom') include_once('scripts/feeds.php');
>>>
>>>The basic functionality of RSS support remains the same as before,
>>>adding ?action=rss or ?action=rdf to a wikitrail page generates a feed
>>>for the pages on the trail.  The ?count=n parameter can be used to
>>>specify the maximum number of items that should be placed in the feed,
>>>while ?order= can specify the order in which items should appear.
>>>Thus:
>>>
>>>   http://www.pmwiki.org/wiki/Site/AllRecentChanges?action=rss
>>>     - RSS 2.0 feed for the PmWiki site
>>>
>>>   http://www.pmwiki.org/wiki/Category/Skins?action=atom&order=-time
>>>     - Atom 1.0 feed for all pages in the Skins category, most
>>>       recently edited first
>>>
>>>   http://www.pmwiki.org/wiki/PmWiki/PmWiki?action=dc
>>>     - Dublin Core Metadata for PmWiki.PmWiki page
>>>
>>>The new script is highly configurable, new elements can be easily
>>>added to feeds via the $FeedFmt array.  Elements in $FeedFmt look like
>>>
>>>       $FeedFmt['atom']['feed']['rights'] = 'All Rights Reserved';
>>>
>>>where the first index corresponds to the action (?action=atom),
>>>the second index indicates a per-feed or per-item element, and
>>>the third index is the name of the element being generated.
>>>The above setting would therefore generate a
>>>"<rights>All Rights Reserved</rights>" in the feed for
>>>?action=atom.  If the value of an entry begins with a '<',
>>>then feeds.php doesn't automatically add the tag around it.
>>>Elements can also be callable functions which are called to
>>>generate the appropriate output.
>>>
>>>In order to properly support these changes, PmWiki has also
>>>improved some of its internal metadata handling.  Descriptions,
>>>keywords, and the initial portion of formatted output (up to
>>>$SaveAttrExcerptLength, default 600 chars) are saved directly
>>>into page files.  
>>>
>>>Lastly, PmWiki has adjusted the way it saves pages so that
>>>trail markup no longer generates internal links to other pages
>>>on the trail (i.e., trail next and previous links no longer appear
>>>in the link index).
>>>
>>>Comments, questions, suggestions welcome as always.
>>>
>>>Pm
>>>
>>>_______________________________________________
>>>pmwiki-users mailing list
>>>pmwiki-users at pmichaud.com
>>>http://host.pmichaud.com/mailman/listinfo/pmwiki-users
>>>
>>
> 




More information about the pmwiki-users mailing list