Open Journal Systems  2.4.4
 All Classes Namespaces Functions Variables Groups Pages
Request.inc.php
1 <?php
2 
19 import('lib.pkp.classes.core.PKPRequest');
20 
21 class Request extends PKPRequest {
27  static $journal;
28  $_this =& PKPRequest::_checkThis();
29 
30  if (!isset($journal)) {
31  $journal = $_this->_delegateToRouter('getRequestedContextPath', 1);
32  HookRegistry::call('Request::getRequestedJournalPath', array(&$journal));
33  }
34 
35  return $journal;
36  }
37 
42  function &getJournal() {
43  $_this =& PKPRequest::_checkThis();
44  $returner = $_this->_delegateToRouter('getContext', 1);
45  return $returner;
46  }
47 
52  function getRequestedContextPath($contextLevel = null) {
53  $_this =& PKPRequest::_checkThis();
54 
55  // Emulate the old behavior of getRequestedContextPath for
56  // backwards compatibility.
57  if (is_null($contextLevel)) {
58  return $_this->_delegateToRouter('getRequestedContextPaths');
59  } else {
60  return array($_this->_delegateToRouter('getRequestedContextPath', $contextLevel));
61  }
62  }
63 
68  function &getContext($level = 1) {
69  $_this =& PKPRequest::_checkThis();
70  $returner = $_this->_delegateToRouter('getContext', $level);
71  return $returner;
72  }
73 
78  function &getContextByName($contextName) {
79  $_this =& PKPRequest::_checkThis();
80  $returner = $_this->_delegateToRouter('getContextByName', $contextName);
81  return $returner;
82  }
83 
88  function url($journalPath = null, $page = null, $op = null, $path = null,
89  $params = null, $anchor = null, $escape = false) {
90  $_this =& PKPRequest::_checkThis();
91  return $_this->_delegateToRouter('url', $journalPath, $page, $op, $path,
92  $params, $anchor, $escape);
93  }
94 
99  function redirectHome() {
100  $_this =& PKPRequest::_checkThis();
101  return $_this->_delegateToRouter('redirectHome');
102  }
103 }
104 
105 ?>
getRequestedJournalPath()
Definition: Request.inc.php:26
& getJournal()
Definition: Request.inc.php:42
Class providing operations associated with HTTP requests. Requests are assumed to be in the format ht...
Definition: Request.inc.php:21
& getContext($level=1)
Definition: Request.inc.php:68
getRequestedContextPath($contextLevel=null)
Definition: Request.inc.php:52
url($journalPath=null, $page=null, $op=null, $path=null, $params=null, $anchor=null, $escape=false)
Definition: Request.inc.php:88
& getContextByName($contextName)
Definition: Request.inc.php:78
call($hookName, $args=null)
Class providing operations associated with HTTP requests.
redirectHome()
Definition: Request.inc.php:99