Beispiel #1
0
     if (!is_array($_POST['enabled'])) {
         $_POST['enabled'] = array();
     }
     foreach ($pluginsAlias as $name) {
         $tikilib->set_preference("wikiplugin_{$name}", in_array($name, $_POST['enabled']) ? 'y' : 'n');
     }
     foreach (glob('temp/cache/wikiplugin_*') as $file) {
         unlink($file);
     }
 }
 if (isset($_POST['delete'])) {
     if (!is_array($_POST['enabled'])) {
         $_POST['enabled'] = array();
     }
     foreach ($pluginsAlias as $name) {
         WikiPlugin_Negotiator_Wiki_Alias::delete($name);
     }
     $pluginsAlias = WikiPlugin_Negotiator_Wiki_Alias::getList();
 }
 if (isset($_POST['textareasetup']) && !in_array($_POST['plugin_alias'], $pluginsReal) && isset($_REQUEST['plugin_alias']) && getCookie('admin_textarea', 'tabs') == 3) {
     // tab=3 is plugins alias tab (TODO improve)
     $info = array('implementation' => $_POST['implementation'], 'description' => array('name' => $_POST['name'], 'description' => $_POST['description'], 'prefs' => array(), 'validate' => $_POST['validate'], 'filter' => $_POST['filter'], 'inline' => isset($_POST['inline']), 'params' => array()), 'body' => array('input' => isset($_POST['ignorebody']) ? 'ignore' : 'use', 'default' => $_POST['defaultbody'], 'params' => array()), 'params' => array());
     if (!empty($_POST['body'])) {
         $info['description']['body'] = $_POST['body'];
     }
     if ($_POST['validate'] == 'none') {
         unset($info['description']['validate']);
     }
     if (empty($_POST['prefs'])) {
         $temp = array("wikiplugin_{$_POST['plugin_alias']}");
     } else {
Beispiel #2
0
 function plugin_alias_delete($name)
 {
     return WikiPlugin_Negotiator_Wiki_Alias::delete($name);
 }