當前位置: 首頁>>代碼示例>>PHP>>正文


PHP plugin::url_arg方法代碼示例

本文整理匯總了PHP中plugin::url_arg方法的典型用法代碼示例。如果您正苦於以下問題:PHP plugin::url_arg方法的具體用法?PHP plugin::url_arg怎麽用?PHP plugin::url_arg使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在plugin的用法示例。


在下文中一共展示了plugin::url_arg方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: redirect

}
@ini_set('memory_limit', $mem_limit);
// Before we continue check whether this is the latest version of the STK, if not. Block access.
stk_version_check();
// From this point we'll be able to use the full STK layout
$template->assign_var('S_STK_FULL_BODY', true);
// Perform some quick tasks here that require the user to be authenticated
perform_authed_quick_tasks($action);
// If they canceled redirect them to the STK index.
if (isset($_POST['cancel'])) {
    redirect(append_sid(STK_INDEX, false, true, $user->session_id));
}
// Setup the plugin manager
$plugin = new plugin();
// Output common stuff
$template->assign_vars(array('U_ACTION' => append_sid(STK_INDEX, $plugin->url_arg(), true, $user->session_id), 'U_ADM_INDEX' => append_sid(PHPBB_ROOT_PATH . 'adm/index.' . PHP_EXT, false, true, $user->session_id), 'U_STK_INDEX' => append_sid(STK_INDEX, false, true, $user->session_id), 'U_STK_LOGOUT' => append_sid(STK_INDEX, 'action=stklogout', true, $user->session_id), 'U_BACK_TOOL' => $plugin->get_part('t') ? append_sid(STK_INDEX, $plugin->url_arg(), true, $user->session_id) : false, 'U_INDEX' => append_sid(PHPBB_ROOT_PATH . 'index.' . PHP_EXT), 'U_LOGOUT' => append_sid(PHPBB_ROOT_PATH . 'ucp.' . PHP_EXT, 'mode=logout', true, $user->session_id), 'USERNAME' => $user->data['username']));
// Does the user want to run a tool?
if ($plugin->get_part('t')) {
    // Load the tool
    $tool = $plugin->load_tool($plugin->get_part('c'), $plugin->get_part('t'));
    // Can we use this tool?
    if (method_exists($tool, 'tool_active')) {
        if (($msg = $tool->tool_active()) !== true) {
            if ($msg === false) {
                $msg = $user->lang['TOOL_NOT_AVAILABLE'];
            } else {
                $msg = isset($user->lang[$msg]) ? $user->lang[$msg] : $msg;
            }
            trigger_error($msg);
        }
    }
開發者ID:napus,項目名稱:support-toolkit,代碼行數:31,代碼來源:index.php

示例2: plugin

// Perform some quick tasks here that require the user to be authenticated
perform_authed_quick_tasks($action);

// If they canceled redirect them to the STK index.
if (isset($_POST['cancel']))
{
	redirect(append_sid(STK_INDEX, false, true, $user->session_id));
}

// Setup the plugin manager
$plugin = new plugin();

// Output common stuff
$template->assign_vars(array(
	'U_ACTION'		=> append_sid(STK_INDEX, $plugin->url_arg(), true, $user->session_id),
	'U_ADM_INDEX'	=> append_sid(PHPBB_ROOT_PATH . 'adm/index.' . PHP_EXT, false, true, $user->session_id),
	'U_ADM_LOGOUT'	=> append_sid(PHPBB_ROOT_PATH . 'adm/index.' . PHP_EXT, 'action=admlogout', true, $user->session_id),
	'U_STK_INDEX'	=> append_sid(STK_INDEX, false, true, $user->session_id),
	'U_STK_LOGOUT'	=> append_sid(STK_INDEX, 'action=stklogout', true, $user->session_id),
	'U_BACK_TOOL'	=> ($plugin->get_part('t')) ? append_sid(STK_INDEX, $plugin->url_arg(), true, $user->session_id) : false,
	'U_INDEX'		=> append_sid(PHPBB_ROOT_PATH . 'index.' . PHP_EXT),
	'U_LOGOUT'		=> append_sid(PHPBB_ROOT_PATH . 'ucp.' . PHP_EXT, 'mode=logout', true, $user->session_id),

	'USERNAME'		=> $user->data['username'],
));

// Does the user want to run a tool?
if ($plugin->get_part('t'))
{
	// Load the tool
開發者ID:sietf,項目名稱:sietf.org,代碼行數:30,代碼來源:index.php


注:本文中的plugin::url_arg方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。