[pmwiki-users] PmWiki as RSS engine
Rogutės
rogutes at googlemail.com
Tue Sep 30 15:39:20 CDT 2008
Christophe David (2008-09-30 16:20):
> Could someone please advise how to generate RSS feeds that list one
> "item" for every page in a pagelist, using the content of each page to
> populate the fields ?
>
> Each page would contain (:title:MyTitle:)
> (:link:MyLink:)(:description:MyDescription:), etc.,
>
> and calling the "feed page" with "?action=rss" would generate a feed with
>
> <item>
> <title></title>
> <link></link>
> <description></description>
> <pubDate></pubDate>
> <guid></guid>
> </item>
>
> filled with the content of the pages.
Hi,
Perhaps you could use something like the following in config.php?
Untested (http://pmwiki.org/wiki/PmWiki/WebFeeds has some explanations):
$FeedFmt['rss']['feed']['title']='WebFeedFromPageVars';
$FeedFmt['rss']['feed']['link']='WebFeedFromPageVars';
$FeedFmt['rss']['feed']['description']='WebFeedFromPageVars';
function WebFeedFromPageVars($pagename, &$page, $tag) {
return "<$tag>".PageTextVar($pagename, $tag)."</$tag>";
}
--
Rogutės
More information about the pmwiki-users
mailing list