]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - lib/plugin/HelloWorld.php
Moved description from html template into plugins.
[SourceForge/phpwiki.git] / lib / plugin / HelloWorld.php
1 <?php // -*-php-*-
2 rcs_id('$Id: HelloWorld.php,v 1.3 2001-12-15 10:54:49 carstenklapp Exp $');
3 /**
4  * A simple demonstration WikiPlugin.
5  */
6 class WikiPlugin_HelloWorld
7 extends WikiPlugin
8 {
9     var $name = "HelloWorld";
10     var $description = "PhpWiki";
11     
12     function getDefaultArguments() {
13         return array('salutation'       => 'Hello,',
14                      'name'                     => 'World');
15     }
16
17     function run($argstr) {
18         extract($this->parseArgs($argstr));
19         
20         return sprintf("<tt>%s %s</tt>", $salutation, $name);
21     }
22 };
23
24 // For emacs users
25 // Local Variables:
26 // mode: php
27 // tab-width: 8
28 // c-basic-offset: 4
29 // c-hanging-comment-ender-p: nil
30 // indent-tabs-mode: nil
31 // End:
32         
33 ?>