Commit 2af6e14d95a2fd57db692fa854137bc3f7eade29

Authored by Michael Joseph
1 parent 20446851

fixes to querystring handling


git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@741 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing 1 changed file with 3 additions and 2 deletions
lib/session/control.inc
... ... @@ -31,11 +31,13 @@ function redirect($url) {
31 31 * @param string additional querystring vars
32 32 */
33 33 function controllerRedirect($action, $queryString) {
  34 + global $default;
34 35 // generate url
35 36 $ctlUrl = generateControllerUrl($action);
36 37 // append the rest of the url
37 38 $url = $ctlUrl . "&$queryString";
38 39 // now redirect
  40 + $default->log->debug("controllerRedirect: redirect to $url");
39 41 redirect($url);
40 42 }
41 43  
... ... @@ -77,8 +79,7 @@ function checkSessionAndRedirect($bRedirect) {
77 79 // verification failed, redirect to login with error message
78 80 $default->log->debug("checkSession:: session check failed");
79 81 $url = $default->owl_root_url . "/control.php?action=loginForm";
80   -
81   - $redirect = urlencode($_SERVER[PHP_SELF]);
  82 + $redirect = urlencode($_SERVER[PHP_SELF] . "?" . $_SERVER["QUERY_STRING"]);
82 83 if ((strlen($redirect) > 1)) {
83 84 $default->log->debug("checkSession:: redirect url=$redirect");
84 85 // this session verification failure represents either the first visit to
... ...