本文整理匯總了PHP中General::mUrl方法的典型用法代碼示例。如果您正苦於以下問題:PHP General::mUrl方法的具體用法?PHP General::mUrl怎麽用?PHP General::mUrl使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類General
的用法示例。
在下文中一共展示了General::mUrl方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: indexAction
public function indexAction()
{
$this->view->indexpage = true;
if ($this->getRequest()->isPost()) {
$auth = General::login(array('no_email' => $this->getRequest()->getParam('twa_email'), 'tx_senha' => $this->getRequest()->getParam('twa_senha')));
if ($auth) {
header("Location: " . $this->view->url(General::mUrl("home")));
} else {
$this->view->login_error = _("Login ou senha incorretos!");
}
}
if (General::isAuth()) {
$goto = $this->getRequest()->getParam('goto');
$goto = urldecode($goto);
if ($goto) {
header("Location: {$goto}");
} else {
header("Location: " . $this->view->url(General::mUrl("home")));
}
}
}
示例2: logoutAction
/**
* Sair do sistema
*/
public function logoutAction()
{
$this->_helper->viewRenderer->setNoRender();
$this->_helper->layout->disableLayout();
// por preucação
unset($_SESSION['tw_auth']);
session_destroy();
header("Location: " . $this->view->url(General::mUrl('index')));
}
示例3: indexAction
public function indexAction()
{
$this->_helper->viewRenderer->setNoRender();
$this->_helper->layout->disableLayout();
header("Location: " . $this->view->url(General::mUrl("home")));
}
示例4: url_post
public function url_post($param)
{
if (is_object($param)) {
$nu_post = $param->nu_post;
} else {
$nu_post = $param['nu_post'];
}
return $this->url(General::mUrl("home/post/id/{$nu_post}"), null, true);
}