1<?php 2if(!defined('DOKU_INC')) define('DOKU_INC',realpath(dirname(__FILE__).'/../../../').'/'); 3if(!defined('DOKU_PLUGIN')) define('DOKU_PLUGIN',DOKU_INC.'lib/plugins/'); 4require_once(DOKU_PLUGIN.'admin.php'); 5 6/** 7 * All DokuWiki plugins to extend the admin function 8 * need to inherit from this class 9 */ 10class admin_plugin_dokukiwix extends DokuWiki_Admin_Plugin { 11 var $cmd; 12 13 /** 14 * Constructor 15 */ 16 function admin_plugin_dokukiwix(){ 17 $this->setupLocale(); 18 } 19 20 /** 21 * return some info 22 */ 23 function getInfo(){ 24 return array( 25 'author' => 'Yann Hamon', 26 'email' => 'yann.hamon@gmail.com', 27 'date' => '2007-06-30', 28 'name' => 'Dokukiwix', 29 'desc' => 'Allows to create an offline version of your Wiki', 30 'url' => 'http://wiki.splitbrain.org/plugin:dokukiwix', 31 ); 32 } 33 34 /** 35 * return sort order for position in admin menu 36 */ 37 function getMenuSort() { 38 return 40; 39 } 40 41 /** 42 * handle user request 43 */ 44 function handle() { 45 } 46 47 /** 48 * output appropriate html 49 */ 50 function html() { 51 print $this->plugin_locale_xhtml('intro'); 52 53 print '<fieldset id="pl_dokukiwix_form">'; 54 print '<span id="pl_dokukiwix_out"></span>'; 55 print '<img src="'.DOKU_BASE.'lib/images/loading.gif" id="pl_dokukiwix_throbber" />'; 56 print '<div id="pl_dokukiwix_actions">'; 57 print '<a href="#" onclick="plugin_dokukiwix_toggle_startpause(); return false;" title="Start"><img src="'.DOKU_BASE.'lib/plugins/dokukiwix/images/play.png" alt="Start" id="pl_dokukiwix_toggle_startpause" /></a> '; 58 //print '<a href="#" onclick="plugin_dokukiwix_cb_skip()" title="Skip"><img src="'.DOKU_BASE.'lib/plugins/dokukiwix/images/skip.png" alt="Skip" /></a>'; 59 print '<a href="#" onclick="plugin_dokukiwix_stop()" title="Stop" id="pl_dokukiwix_stop" style="visibility:hidden;"><img src="'.DOKU_BASE.'lib/plugins/dokukiwix/images/stop.png" alt="Stop" /></a>'; 60 print '</div>'; 61 print '<div><textarea readonly="1" id="pl_dokukiwix_log"></textarea></div>'; 62 print '</fieldset>'; 63 64 65 print '<p>Dokukiwix is subject to the <a href="http://www.gnu.org/copyleft/gpl.html">GPL v2</a> license.</p>'; 66 } 67 68 69} 70//Setup VIM: ex: et ts=4 enc=utf-8 : 71