本文整理匯總了PHP中TGM_Plugin_Activation::install_plugins_page方法的典型用法代碼示例。如果您正苦於以下問題:PHP TGM_Plugin_Activation::install_plugins_page方法的具體用法?PHP TGM_Plugin_Activation::install_plugins_page怎麽用?PHP TGM_Plugin_Activation::install_plugins_page使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類TGM_Plugin_Activation
的用法示例。
在下文中一共展示了TGM_Plugin_Activation::install_plugins_page方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: explode
}
switch ($this->navigation) {
case 'add-plugin':
if (!isset($_POST['plug-submit'])) {
include_once 'views/add-plugin.php';
} else {
if (empty($_POST) || !wp_verify_nonce($_POST['plugin-upload-field'], 'plugin-upload-action')) {
print __('Sorry, your nonce did not verify.', 'framework');
exit;
} else {
if (isset($_FILES['plugzip']['name']) && $_FILES['plugzip']['name'] != '') {
$exploded = explode('.', $_FILES['plugzip']['name']);
$file_ext = array_pop($exploded);
if ($file_ext == 'zip') {
$plugin_installer->load_new_plugin($_FILES['plugzip']);
$tgm->install_plugins_page();
echo $redirect;
} else {
$info_message = __('File must have <b>.zip</b> extension Please choose another file.', 'framework');
include_once 'views/add-plugin.php';
}
} else {
$info_message = __('Select a file', 'framework');
include_once 'views/add-plugin.php';
}
}
}
break;
case 'extensions':
global $extm;
$vals['extm'] = $extm;