bug REQUEST_URI mtweb.0.11.5
authordj3c1t <dj3c1t@free.fr>
Mon, 25 Nov 2013 20:58:25 +0000 (21:58 +0100)
committerdj3c1t <dj3c1t@free.fr>
Mon, 25 Nov 2013 20:58:25 +0000 (21:58 +0100)
mw/mw_app.php

index 4355487..4b0b2eb 100644 (file)
     }
 
     function init_pathes(){
-      if(($n = strpos($_SERVER["REQUEST_URI"], "?")) !== false){
-        $_SERVER["REQUEST_URI"] = substr($_SERVER["REQUEST_URI"], 0, $n);
+      $REQUEST_URI = $_SERVER["REQUEST_URI"];
+      if(($n = strpos($REQUEST_URI, "?")) !== false){
+        $REQUEST_URI = substr($REQUEST_URI, 0, $n);
       }
-      $web_path = explode("/", preg_replace('#/+#','/',$_SERVER["REQUEST_URI"]));
+      $web_path = explode("/", preg_replace('#/+#','/',$REQUEST_URI));
       $this->pathes["web"] = "";
       for($i = 0; $i < count($web_path) - 1; $i++) $this->pathes["web"] .= $web_path[$i]."/";
       if(