diff --git a/index.php b/index.php index b062a43322..9344336f48 100755 --- a/index.php +++ b/index.php @@ -22,7 +22,8 @@ if(!$GLOBALS['sessionid']) { Header('Location: login.php'. - (isset($_SERVER['QUERY_STRING']) ? '?phpgw_forward='.urlencode('/index.php?'.$_SERVER['QUERY_STRING']):'')); + (isset($_SERVER['QUERY_STRING']) && !empty($_SERVER['QUERY_STRING']) ? + '?phpgw_forward='.urlencode('/index.php?'.$_SERVER['QUERY_STRING']):'')); exit; }