示例#1
0
 /**
  * Removes the template if necessary
  */
 protected function BeforeInit()
 {
     if ($this->RemoveTemplate()) {
         Response::Redirect(Request::Uri());
         return true;
     }
     parent::BeforeInit();
 }
 /**
  * Can be used to add logic after deletion in using classes;
  * by default, it redirects to the current url
  */
 protected function AfterRemove()
 {
     Response::Redirect(Request::Uri());
     return true;
 }
示例#3
0
/**
 * The current uri (without base url)
 * @return string Returns the current uri
 */
function CurrentUri()
{
    return Request::Uri();
}
示例#4
0
 /**
  * The backend url; CAUTION: This only works in backend pages!!!
  * return string
  */
 static function BackendUrl()
 {
     return Path::Directory(Request::Uri());
 }