diff options
Diffstat (limited to 'lib/private/request.php')
-rwxr-xr-x | lib/private/request.php | 36 |
1 files changed, 5 insertions, 31 deletions
diff --git a/lib/private/request.php b/lib/private/request.php index c3e28a9f08b..14f3bf2cbb7 100755 --- a/lib/private/request.php +++ b/lib/private/request.php @@ -103,6 +103,7 @@ class OC_Request { * * Returns the request uri, even if the website uses one or more * reverse proxies + * @return string */ public static function requestUri() { $uri = isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : ''; @@ -114,7 +115,7 @@ class OC_Request { /** * @brief Returns the script name - * @returns string the script name + * @return string the script name * * Returns the script name, even if the website uses one or more * reverse proxies @@ -131,7 +132,7 @@ class OC_Request { /** * @brief get Path info from request - * @returns string Path info or false when not found + * @return string Path info or false when not found */ public static function getPathInfo() { if (array_key_exists('PATH_INFO', $_SERVER)) { @@ -155,7 +156,7 @@ class OC_Request { /** * @brief get Path info from request, not urldecoded - * @returns string Path info or false when not found + * @return string Path info or false when not found */ public static function getRawPathInfo() { $requestUri = $_SERVER['REQUEST_URI']; @@ -195,35 +196,8 @@ class OC_Request { } /** - * @brief Check if this is a no-cache request - * @returns boolean true for no-cache - */ - static public function isNoCache() { - if (!isset($_SERVER['HTTP_CACHE_CONTROL'])) { - return false; - } - return $_SERVER['HTTP_CACHE_CONTROL'] == 'no-cache'; - } - - /** - * @brief Check if the requestor understands gzip - * @returns boolean true for gzip encoding supported - */ - static public function acceptGZip() { - if (!isset($_SERVER['HTTP_ACCEPT_ENCODING'])) { - return false; - } - $HTTP_ACCEPT_ENCODING = $_SERVER["HTTP_ACCEPT_ENCODING"]; - if( strpos($HTTP_ACCEPT_ENCODING, 'x-gzip') !== false ) - return 'x-gzip'; - else if( strpos($HTTP_ACCEPT_ENCODING, 'gzip') !== false ) - return 'gzip'; - return false; - } - - /** * @brief Check if the requester sent along an mtime - * @returns false or an mtime + * @return false or an mtime */ static public function hasModificationTime () { if (isset($_SERVER['HTTP_X_OC_MTIME'])) { |