WebFetch::Output::TWiki - WebFetch output to TWiki web site
This is an output module for WebFetch which places the data in pages on a TWiki web site. Some of its configuration information is read from a TWiki page. Calling or command-line parameters point to the TWiki page which has the configuration and a search key to locate the correct line in a table.
From the command line...
perl -w -I$libdir -MWebFetch::Input::Atom -MWebFetch::Output::TWiki -e "&fetch_main" -- --dir "/path/to/fetch/worskspace" --source "http://search.twitter.com/search.atom?q=%23twiki" --dest=twiki --twiki_root=/var/www/twiki --config_topic=Feeds.WebFetchConfig --config_key=twiki
From Perl code...
use WebFetch; my $obj = WebFetch->new( "dir" => "/path/to/fetch/workspace", "source" => "http://search.twitter.com/search.atom?q=%23twiki", "source_format" => "atom", "dest" => "twiki", "dest_format" = "twiki", "twiki_root" => "/var/www/twiki", "config_topic" => "Feeds.WebFetchConfig", "config_key" => "twiki", ); $obj->do_actions; # process output $obj->save; # save results
The configuration information on feeds is kept in a TWiki page. You can specify any page with a web and topic name, for example
The contents of that configuration page could look like this, though with any feeds you want to configure. The "Key" field matches the --config_key command-line parameter, and then brings in the rest of the configuration info from that line. An example is shown below.
The following table is used by !WebFetch to configure news feeds
| *Key* | *Web* | *Parent* | *Prefix* | *Template* | *Form* | *Options* | *Modul e* | *Source* |
| ikluft-twitter | Feeds | TwitterIkluftFeed | TwitterIkluft | AtomFeedTemplate | AtomFeedForm | separate_topics | Atom | http://twitter.com/statuses/user_timeline/37786023.rss |
| twiki-twitter | Feeds | TwitterTwikiFeed | TwitterTwiki | AtomFeedTemplate | AtomFeedForm | separate_topics | Atom | http://search.twitter.com/search.atom?q=%23twiki |
| cnn | Feeds | RssCnn | RssCnn | RssFeedTemplate | RssFeedForm | separate_topics | RSS | http://rss.cnn.com/rss/cnn_topstories.rss |
%STOPINCLUDE% are not required. However, if present, they are used as boundaries for the inclusion like in a normal INCLUDE operation on TWiki.
TWiki is a wiki (user-editable web site) with features enabling collaboration in an enterprise environment. It implements the concept of a "structured wiki", allowing structure and automation as needed and retaining the informality of a wiki. Automated input/updates such as from WebFetch::Output::TWiki is one example.
See http://twiki.org/ for the Open Source community-maintained software or http://twiki.net/ for enterprise support.
WebFetch::Output::TWiki was developed for TWiki Inc (formerly TWiki.Net).
WebFetch was written by Ian Kluft Send patches, bug reports, suggestions and questions to
Please report any bugs or feature requests to
bug-webfetch-output-twiki at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=WebFetch-Output-TWiki. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
2 POD Errors
The following errors were encountered while parsing the POD:
- Around line 117:
=over should be: '=over' or '=over positive_number'
- Around line 510:
You forgot a '=back' before '=head1'