Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

wiki::toolkit::plugin::rss::reader(3pm) [debian man page]

Wiki::Toolkit::Plugin::RSS::Reader(3pm) 		User Contributed Perl Documentation		   Wiki::Toolkit::Plugin::RSS::Reader(3pm)

NAME
Wiki::Toolkit::Plugin::RSS::Reader - retrieve RSS feeds for inclusion in Wiki::Toolkit nodes DESCRIPTION
Use this Wiki::Toolkit plugin to retrieve an RSS feed from a given URL so that you can include it in a wiki node. SYNOPSIS
use Wiki::Toolkit::Plugin::RSS::Reader; my $rss = Wiki::Toolkit::Plugin::RSS::Reader->new( url => 'http://example.com/feed.rss' ); my @items = $rss->retrieve; USAGE
This is a plugin for Wiki::Toolkit, a toolkit for building wikis; therefore please consult the documentation for Wiki::Toolkit for relevant information. This module can, however, be used standalone if you wish. METHODS
"new" my $rss = Wiki::Toolkit::Plugin::RSS::Reader->new([options]); Create a new RSS reader. Valid options are "url" or "file" (a path to an RSS file); only one can be specified. "retrieve" my @items = $rss->retrieve; "retrieve" will return an array of hashes, one for each item in the RSS feed. The hashes contain three items, "title", "link", and "description". If the URL or file you specified cannot be retrieved/read, "retrieve" will return undef rather than blowing up and surprising the person reading your wiki. If you want, you can specify "debug" to be 1 in the options to "new", which will cause the module to croak instead of failing silently. AUTHOR
Earle Martin (EMARTIN@cpan.org) The Wiki::Toolkit team, (http://www.wiki-toolkit.org/) LEGAL
Copyright 2004 Earle Martin. Copyright 2006 the Wiki::Toolkit team. This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.10.1 2009-10-25 Wiki::Toolkit::Plugin::RSS::Reader(3pm)

Check Out this Related Man Page

Wiki::Toolkit::Feed::Atom(3pm)				User Contributed Perl Documentation			    Wiki::Toolkit::Feed::Atom(3pm)

NAME
Wiki::Toolkit::Feed::Atom - A Wiki::Toolkit plugin to output RecentChanges Atom. DESCRIPTION
This is an alternative access to the recent changes of a Wiki::Toolkit wiki. It outputs the Atom Syndication Format as described at <http://www.atomenabled.org/developers/syndication/>. This module is a straight port of Wiki::Toolkit::Feed::RSS. SYNOPSIS
use Wiki::Toolkit; use Wiki::Toolkit::Feed::Atom; my $wiki = Wiki::Toolkit->new( ... ); # See perldoc Wiki::Toolkit # Set up the RSS feeder with the mandatory arguments - see # C<new()> below for more, optional, arguments. my $atom = Wiki::Toolkit::Feed::Atom->new( wiki => $wiki, site_name => 'My Wiki', site_url => 'http://example.com/', make_node_url => sub { my ($node_name, $version) = @_; return 'http://example.com/?id=' . uri_escape($node_name) . ';version=' . uri_escape($version); }, html_equiv_link => 'http://example.com/?RecentChanges', atom_link => 'http://example.com/?action=rc;format=atom', ); print "Content-type: application/atom+xml "; print $atom->recent_changes; METHODS
"new()" my $atom = Wiki::Toolkit::Feed::Atom->new( # Mandatory arguments: wiki => $wiki, site_name => 'My Wiki', site_url => 'http://example.com/', make_node_url => sub { my ($node_name, $version) = @_; return 'http://example.com/?id=' . uri_escape($node_name) . ';version=' . uri_escape($version); }, html_equiv_link => 'http://example.com/?RecentChanges',, atom_link => 'http://example.com/?action=rc;format=atom', # Optional arguments: site_description => 'My wiki about my stuff', software_name => $your_software_name, # e.g. "Wiki::Toolkit" software_version => $your_software_version, # e.g. "0.73" software_homepage => $your_software_homepage, # e.g. "http://search.cpan.org/dist/CGI-Wiki/" encoding => 'UTF-8' ); "wiki" must be a Wiki::Toolkit object. "make_node_url", if supplied, must be a coderef. The mandatory arguments are: o wiki o site_name o site_url o make_node_url o html_equiv_link or recent_changes_link o atom_link The three optional arguments o software_name o software_version o software_homepage are used to generate the "generator" part of the feed. The optional argument o encoding will be used to specify the character encoding in the feed. If not set, will default to the wiki store's encoding. "recent_changes()" $wiki->write_node( 'About This Wiki', 'blah blah blah', $checksum, { comment => 'Stub page, please update!', username => 'Fred', } ); print "Content-type: application/atom+xml "; print $atom->recent_changes; # Or get something other than the default of the latest 15 changes. print $atom->recent_changes( items => 50 ); print $atom->recent_changes( days => 7 ); # Or ignore minor edits. print $atom->recent_changes( ignore_minor_edits => 1 ); # Personalise your feed further - consider only changes # made by Fred to pages about bookshops. print $atom->recent_changes( filter_on_metadata => { username => 'Fred', category => 'Bookshops', }, ); If using "filter_on_metadata", note that only changes satisfying all criteria will be returned. Note: Many of the fields emitted by the Atom generator are taken from the node metadata. The form of this metadata is not mandated by Wiki::Toolkit. Your wiki application should make sure to store some or all of the following metadata when calling "write_node": comment - a brief comment summarising the edit that has just been made; will be used in the summary for this item. Defaults to the empty string. username - an identifier for the person who made the edit; will be used as the Dublin Core contributor for this item, and also in the RDF description. Defaults to 'No description given for change'. host - the hostname or IP address of the computer used to make the edit; if no username is supplied then this will be used as the author for this item. Defaults to 'Anonymous'. "generate_node_list_feed" Generate and return an Atom feed for a list of nodes "generate_node_name_distance_feed" Generate a very cut down atom feed, based just on the nodes, their locations (if given), and their distance from a reference location (if given). Typically used on search feeds. "feed_timestamp()" print $atom->feed_timestamp(); Returns the timestamp of the feed in POSIX::strftime style ("Tue, 29 Feb 2000 12:34:56 GMT"), which is equivalent to the timestamp of the most recent item in the feed. Takes the same arguments as recent_changes(). You will most likely need this to print a Last-Modified HTTP header so user-agents can determine whether they need to reload the feed or not. "parse_feed_timestamp" Take a feed_timestamp and return a Time::Piece object. SEE ALSO
o Wiki::Toolkit o <http://www.atomenabled.org/developers/syndication/> MAINTAINER
The Wiki::Toolkit team, http://www.wiki-toolkit.org/. COPYRIGHT AND LICENSE
Copyright 2006-2009 Earle Martin and the Wiki::Toolkit team. Copyright 2012 the Wiki::Toolkit team. This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. THANKS
Kake Pugh for originally writing Wiki::Toolkit::Feed::RSS and indeed Wiki::Toolkit itself. perl v5.14.2 2012-05-28 Wiki::Toolkit::Feed::Atom(3pm)
Man Page