note 68012 deleted from function.dirname by danbrown
| From: | danbrown@php.net | Date: | Sun, 20 Jul 2008 19:04:55 +0000 |
| Subject: | note 68012 deleted from function.dirname by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-142263@lists.php.net to get a copy of this message | ||
Note Submitter: legolas558 dot sourceforge comma net
----
I have to disagree with <jo _at durchholz dout org>
In some installations (< 4.4.1, cannot be more precise) $_SERVER['REQUEST_URI'] is not
set, I used the below code to fix it
<?php
if (!isset($_SERVER['REQUEST_URI'])) {
$_SERVER['REQUEST_URI'] = substr($_SERVER['PHP_SELF'],1);
if (isset($_SERVER['QUERY_STRING']))
$_SERVER['REQUEST_URI'].='?'.$_SERVER['QUERY_STRING'];
}
?>