php's build in webserver doesn't populate QUERY_STRING when none is passed.
php's build in webserver doesn't populate QUERY_STRING when none is passed.
This commit fixes the warning.

Signed-off-by: Chris Han <xiphux@gmail.com>

--- a/include/controller/ControllerBase.class.php
+++ b/include/controller/ControllerBase.class.php
@@ -558,7 +558,11 @@
 			$this->tpl->assign('router', $this->router);
 		}
 
-		$getvars = explode('&', $_SERVER['QUERY_STRING']);
+        $getvars = array();
+        if (isset($_SERVER['QUERY_STRING'])) {
+    		$getvars = explode('&', $_SERVER['QUERY_STRING']);
+        }
+
 		$getvarsmapped = array();
 		foreach ($getvars as $varstr) {
 			$eqpos = strpos($varstr, '=');

comments