本文整理匯總了PHP中Registry::getUrl方法的典型用法代碼示例。如果您正苦於以下問題:PHP Registry::getUrl方法的具體用法?PHP Registry::getUrl怎麽用?PHP Registry::getUrl使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Registry
的用法示例。
在下文中一共展示了Registry::getUrl方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: delete
public function delete()
{
$url = Registry::getUrl();
$id = $_REQUEST["id"] ? $_REQUEST["id"] : $url->vars[0];
$user = new User($id);
if ($user->id) {
if ($user->delete()) {
Registry::addMessage("Usuario eliminado satisfactoriamente", "success");
}
}
Url::redirect(Url::site("users"));
}
示例2: delete
public function delete()
{
$url = Registry::getUrl();
$id = $_REQUEST["id"] ? $_REQUEST["id"] : $url->vars[0];
$tipo = new Tipo($id);
if ($tipo->id) {
if ($tipo->delete()) {
Registry::addMessage("Tipo de entrada eliminado satisfactoriamente", "success");
}
}
Url::redirect(Url::site("tipos"));
}
示例3: rememberFilter
function rememberFilter($name)
{
$url = Registry::getUrl();
$app = $url->app;
if (isset($_REQUEST[$name])) {
if (!$_REQUEST[$name]) {
unset($_SESSION[$app . '.' . $name]);
} else {
$_SESSION[$app . '.' . $name] = $_REQUEST[$name];
}
} else {
$_REQUEST[$name] = $_SESSION[$app . '.' . $name];
}
}
示例4: delete
public function delete()
{
$url = Registry::getUrl();
$id = $_REQUEST["id"] ? $_REQUEST["id"] : $url->vars[0];
$mosca = new Mosca($id);
if ($mosca->id) {
if ($mosca->delete()) {
Registry::addMessage("Mosca eliminada satisfactoriamente", "success");
//Log
Log::add(LOG_DELETE_MOSCA, $mosca);
}
}
Url::redirect(Url::site("moscas"));
}
示例5: defined
<?php
defined('_EXE') or die('Restricted access');
?>
<?php
$pages = $pag['limit'] ? ceil($pag['total'] / $pag['limit']) : $pag['total'];
$url = Registry::getUrl();
$app = $url->app;
$action = $url->action;
?>
<?php
if ($pages) {
?>
<ul class="pagination">
<li class="<?php
if ($pag['limitStart'] / $pag['limit'] == 0) {
echo "disabled";
}
?>
">
<a data-app="<?php
echo $app;
?>
" data-action="<?php
echo $action;
?>
" data-limit="<?php
echo (int) $pag['limit'];
?>
示例6: delete
public function delete()
{
$url = Registry::getUrl();
$id = $_REQUEST["id"] ? $_REQUEST["id"] : $url->vars[0];
$entrada = new Entrada($id);
if ($entrada->id) {
if ($entrada->delete()) {
Registry::addMessage("Entrada eliminada satisfactoriamente", "success");
//Log
Log::add(LOG_DELETE_ENTRADA, $entrada);
}
}
Url::redirect(Url::site("entradas"));
}