setupLocale(); } /** * return some info */ function getInfo(){ return array( 'author' => 'Andreas Gohr', 'email' => 'andi@splitbrain.org', 'date' => '2007-04-22', 'name' => 'Revert Manager', 'desc' => 'Allows you to mass revert recent edits', 'url' => 'http://wiki.splitbrain.org/plugin:revert', ); } /** * access for managers */ function forAdminOnly(){ return false; } /** * return sort order for position in admin menu */ function getMenuSort() { return 40; } /** * handle user request */ function handle() { } /** * output appropriate html */ function html() { echo $this->plugin_locale_xhtml('intro'); $this->_searchform(); if(is_array($_REQUEST['revert'])){ $this->_revert($_REQUEST['revert'],$_REQUEST['filter']); }elseif(isset($_REQUEST['filter'])){ $this->_list($_REQUEST['filter']); } } /** * Display the form for searching spam pages */ function _searchform(){ global $lang; echo '
'; echo ''; echo ''; echo ''; echo ' '.$this->getLang('note1').''; echo '


'; } /** * Start the reversion process */ function _revert($revert,$filter){ global $conf; echo '

'; echo '

'.$this->getLang('revstart').'

'; echo ''; echo '

'.$this->getLang('revstop').'

'; } /** * List recent edits matching the given filter */ function _list($filter){ global $conf; echo '

'; echo '
'; echo ''; $recents = getRecents(0,$this->max_lines); echo ''; echo '

'; echo ' '; printf($this->getLang('note2'),hsc($filter)); echo '

'; echo '
'; } } //Setup VIM: ex: et ts=4 enc=utf-8 :