This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if( !function_exists('apache_request_headers') ) { | |
function apache_request_headers() { | |
$arh = array(); | |
$rx_http = '/\AHTTP_/'; | |
foreach($_SERVER as $key => $val) { | |
if( preg_match($rx_http, $key) ) { | |
$arh_key = preg_replace($rx_http, '', $key); | |
$rx_matches = array(); | |
// do some nasty string manipulations to restore the original letter case |