Изменен механизм расширения ссылок. Избавление от глобальных переменных
This commit is contained in:
parent
524b27936a
commit
40fad0e75b
11 changed files with 77 additions and 61 deletions
|
|
@ -9,10 +9,6 @@ use Exception,
|
|||
ctiso\Collection,
|
||||
ctiso\Session;
|
||||
|
||||
class WrongRequestException extends Exception
|
||||
{
|
||||
}
|
||||
|
||||
// HTTPRequest = ArrayAccess
|
||||
class HttpRequest extends Collection implements ArrayAccess
|
||||
{
|
||||
|
|
@ -132,4 +128,8 @@ class HttpRequest extends Collection implements ArrayAccess
|
|||
|
||||
public function offsetGet($key) {
|
||||
}
|
||||
|
||||
static function getProtocol() {
|
||||
return (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' || $_SERVER['SERVER_PORT'] == 443) ? "https://" : "http://";
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue