use strict; use warnings; package Wiki::Toolkit::Formatter::XHTMLMediaWiki; use base 'XHTML::MediaWiki'; =head1 NAME Wiki::Toolkit::Formatter::XHTMLMediaWiki - A Mediawiki-style formatter for Wiki::Toolkit. =head1 VERSION Version 0.04 =cut use vars qw{$VERSION}; $VERSION = '0.04'; =head1 SYNOPSIS This package implements a formatter for the Wiki::Toolkit module which attempts to duplicate the behavior of the Mediawiki application (a set of PHP scripts used by Wikipedia and friends). use Wiki::Toolkit use Wiki::Toolkit::Store::Mediawiki; use Wiki::Toolkit::Formatter::XHTMLMediaWiki; my $store = Wiki::Toolkit::Store::Mediawiki->new( ... ); # See below for parameter details. my $formatter = Wiki::Toolkit::Formatter::XHTMLMediaWiki->new( store => $store ); my $wiki = Wiki::Toolkit->new(store => $store, formatter => $formatter); =cut use Carp qw(croak); =head1 METHODS =head2 new my $formatter = Wiki::Toolkit::Formatter::XHTMLMediaWiki->new( store => $store ); See: L for other arguments =cut sub new { my ($class, %args) = @_; # croak "`store' is a required argument" unless $args{store}; my $store = $args{store}; delete $args{store}; my $self = $class->SUPER::new(%args); $self->{store} = $store; return $self; } 1; # End of Wiki::Toolkit::Formatter::XHTMLMediaWiki __END__ =head2 format my $html = $formatter->format($content); This is the main method. You give this method C and it returns C. =cut =head1 SEE ALSO =over 4 =item L =item L =item L =item L =item L =back =head1 AUTHOR "G. Allen Morris III" C<< >> =head1 BUGS Please report any bugs or feature requests to C, or through the web interface at L. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes. =head1 SUPPORT You can find more information at: =over 4 =item * AnnoCPAN: Annotated CPAN documentation L =item * CPAN Ratings L =item * RT: CPAN's request tracker L =item * Search CPAN L =back =head1 EXAMPLE There is a simple example C file in the examples directory of the distribution. =head1 COPYRIGHT & LICENSE Copyright 2008 G. Allen Morris III, all rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. =cut