get_error_message() ); wp_redirect('plugins.php?activate=true'); // overrides the ?error=true one above } elseif ('error_scrape' == $_GET['action']) { $plugin = trim($_GET['plugin']); check_admin_referer('plugin-activation-error_' . $plugin); if ( validate_file($plugin) ) wp_die(__('Invalid plugin.')); if ( ! file_exists(ABSPATH . PLUGINDIR . '/' . $plugin) ) wp_die(__('Plugin file does not exist.')); include(ABSPATH . PLUGINDIR . '/' . $plugin); } elseif ('deactivate' == $_GET['action']) { check_admin_referer('deactivate-plugin_' . $_GET['plugin']); deactivate_plugins($_GET['plugin']); wp_redirect('plugins.php?deactivate=true'); } elseif ($_GET['action'] == 'deactivate-all') { check_admin_referer('deactivate-all'); deactivate_all_plugins(); wp_redirect('plugins.php?deactivate-all=true'); } exit; } $title = __('Manage Plugins'); require_once('admin-header.php'); // Clean up options // If any plugins don't exist, axe 'em $check_plugins = get_option('active_plugins'); // Sanity check. If the active plugin list is not an array, make it an // empty array. if ( !is_array($check_plugins) ) { $check_plugins = array(); update_option('active_plugins', $check_plugins); } // If a plugin file does not exist, remove it from the list of active // plugins. foreach ($check_plugins as $check_plugin) { if (!file_exists(ABSPATH . PLUGINDIR . '/' . $check_plugin)) { $current = get_option('active_plugins'); $key = array_search($check_plugin, $current); if ( false !== $key && NULL !== $key ) { unset($current[$key]); update_option('active_plugins', $current); } } } ?>
fatal error.') ?>
activated.') ?>
deactivated.') ?>
deactivated.'); ?>
> | ||||
---|---|---|---|---|
{$plugin_data['Title']} | {$plugin_data['Version']} | {$plugin_data['Description']}$author |
$toggle | "; if ( current_user_can('edit_plugins') ) echo "$edit | "; echo"
%s directory and it will be automatically deactivated.'), PLUGINDIR); ?>
WordPress plugin directory.'); ?>
%s directory. Once a plugin is uploaded, you may activate it here.'), PLUGINDIR); ?>