~ubuntu-branches/ubuntu/oneiric/libhtml-wikiconverter-perl/oneiric

« back to all changes in this revision

Viewing changes to t/complete.docuwiki

  • Committer: Bazaar Package Importer
  • Author(s): Jonas Genannt
  • Date: 2006-01-09 20:19:12 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20060109201912-306xp7tjdjcwejlu
Tags: 0.40-1
New Upstream Release

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
====== HTML::WikiConverter ======
2
 
 
3
 
HTML::WikiConverter is a Perl module for converting HTML to wiki markup for a variety of different wiki engines. Currently, it supports **eleven** dialects:
4
 
 
5
 
  * DocuWiki 
6
 
  * Kwiki 
7
 
  * MediaWiki 
8
 
  * MoinMoin 
9
 
  * Oddmuse 
10
 
  * PhpWiki 
11
 
  * PmWiki 
12
 
  * SnipSnap 
13
 
  * TikiWiki 
14
 
  * UseMod 
15
 
  * WakkaWiki 
16
 
 
17
 
I'd //really// like to add support for TWiki, but the way it handles //**bold italics**// (and possibly other nested elements) is very disappointing.
18
 
 
19
 
===== Installation =====
20
 
 
21
 
It's very easy to use HTML::WikiConverter. Grab a copy from your favorite [[http://www.cpan.org|CPAN mirror]] and then run something like this:
22
 
 
23
 
    #!/usr/bin/perl -w
24
 
    use HTML::WikiConverter;
25
 
    my $wc = new HTML::WikiConverter( dialect => 'MediaWiki' );
26
 
    print $wc->html2wiki($html);
27
 
 
28
 
----
29
 
 
30
 
Alternatively, you might want to try HTML::WikiConverter's command line interface; it's a program called "html2wiki" and it's stored in //bin/html2wiki//.
31
 
 
32
 
===== Dialect features =====
33
 
 
34
 
Unfortunately, I haven't managed to implement every feature of each supported dialect. My initial goal was simply to create a converter for MediaWiki (I am a Wikipediholic, after all :-), but then PhpWiki's Reini Urban suggested that I be more ambitious and provide the dialect interface. And so far I've been really happy with the progress.
35
 
 
36
 
===== Bugs =====
37
 
 
38
 
Of course there are always bugs. Luckily, CPAN comes to the rescue again with its [[http://rt.cpan.org|bug tracking service]] for module authors.
39
 
 
40
 
But where would we be without bugs? My Pacman frog sure wouldn't be happy without 'em! Do you know what a [[http://en.wikipedia.org/wiki/Pacman_frog|Pacman frog]] is? Or how about an Otago skink? Aplysia californica? Why, these are some of my favorite animals!
41
 
 
42
 
My favorite animals
43
 
^ Animal ^ Region ^ Physical traits ^ Food ^
44
 
| Pacman frog | Gran Chaco (Argentina) | Half mouth, half stomach (quite literally!) | Crickets, fish, etc. |
45
 
| Otago skink | Otago (New Zealand) | Black, yellow, and green camouflage | Insects, fruits, small lizards |
46
 
| Aplysia california | California | Deep red-colored sea hare | Red and brown seaweed |
47
 
 
48
 
===== Common features =====
49
 
 
50
 
==== Images ====
51
 
 
52
 
Many dialects allow embedded images, either from local or remote stores.
53
 
 
54
 
{{http://www.google.com/images/logo.gif|Google logo}}
55
 
 
56
 
==== Lists ====
57
 
 
58
 
Wikis also support lists, even extensively nested ones. Some rely on leading characters to determine nest levels, while others rely on spaces or (egad!) tabs.
59
 
 
60
 
  * 1   
61
 
    * 1a
62
 
    * 1b 
63
 
  * 2   
64
 
    * 2a 
65
 
      - fee
66
 
      - fie
67
 
      - foe   
68
 
        * fum?  
69
 
 
70
 
Some wikis support definition lists, though they're often used inappropriately (as in MediaWiki, which uses them for indentation).
71
 
 
72
 
PerlPathologically eclectic rubbish listerPOEPerl on ecstacy