summaryrefslogtreecommitdiff
path: root/program/include/rcube_shared.inc
diff options
context:
space:
mode:
authorthomascube <thomas@roundcube.net>2007-09-24 08:42:14 +0000
committerthomascube <thomas@roundcube.net>2007-09-24 08:42:14 +0000
commit5a6efffd36c00783adde326105e1158cee2e5277 (patch)
treef1f945e4a6d4d8633ccd9cad930ed8daab5ad983 /program/include/rcube_shared.inc
parentf45bbe6d4c0d788a2360850e78ca2fe8c75d48d7 (diff)
Removed comments; codestyle
Diffstat (limited to 'program/include/rcube_shared.inc')
-rw-r--r--program/include/rcube_shared.inc20
1 files changed, 8 insertions, 12 deletions
diff --git a/program/include/rcube_shared.inc b/program/include/rcube_shared.inc
index 5349ad0dd..a5a3ca64e 100644
--- a/program/include/rcube_shared.inc
+++ b/program/include/rcube_shared.inc
@@ -530,23 +530,19 @@ function rc_strrpos($haystack, $needle, $offset=0)
* @return mixed Header value or null if not available
*/
function rc_request_header($name)
- {
+{
if (function_exists('getallheaders'))
- {
- $hdrs = getallheaders();
- $hdrs = array_change_key_case($hdrs, CASE_UPPER);
+ {
+ $hdrs = array_change_key_case(getallheaders(), CASE_UPPER);
$key = strtoupper($name);
- }
+ }
else
- {
+ {
$key = 'HTTP_' . strtoupper(strtr($name, '-', '_'));
$hdrs = array_change_key_case($_SERVER, CASE_UPPER);
- }
- if (isset($hdrs[$key]))
- {
- return $hdrs[$key];
- }
- return null;
+ }
+
+ return $hdrs[$key];
}