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_listeabo extends DokuWiki_Admin_Plugin { 11 var $cmd; 12 13 /** 14 * Constructor 15 */ 16 function admin_plugin_listeabo() { 17 $this->setupLocale(); 18 } 19 20 /** 21 * return some info 22 */ 23 function getInfo() { 24 return array( 25 'author' => 'Etienne M.', 26 'email' => 'emauvaisfr@yahoo.fr', 27 'date' => @file_get_contents(DOKU_PLUGIN.'listeabo/VERSION'), 28 'name' => 'Abonnements / Subscriptions', 29 'desc' => 'Affiche tous les abonnements actifs / Displays all active subscriptions', 30 'url' => 'http://www.dokuwiki.org/fr:plugin:listeabo', 31 ); 32 } 33 34 /** 35 * return prompt for admin menu 36 */ 37 function getMenuText($language) { 38 if (!$this->disabled) 39 return parent::getMenuText($language); 40 return ''; 41 } 42 43 /** 44 * return sort order for position in admin menu 45 */ 46 function getMenuSort() { 47 return 5000; 48 } 49 50 /** 51 * handle user request 52 */ 53 function handle() { 54 } 55 56 /** 57 * output appropriate html 58 */ 59 function html() { 60 //Bourrin... Voir plutot avec la fonction handle(), un jour... 61 print '<script>document.location.search="do=listeabo&admin=true";</script>'; 62 } 63} 64// vim:ts=4:sw=4:et:enc=utf-8: 65