Commit 7b91045507463a54599823ea61aed644e9d5ff7e
1 parent
ff138d27
Added functionality to deal with inability to set the action query string variab…
…le when submitting the search page via a get git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@1110 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing
1 changed file
with
10 additions
and
6 deletions
control.php
| @@ -22,14 +22,17 @@ require_once("./config/dmsDefaults.php"); | @@ -22,14 +22,17 @@ require_once("./config/dmsDefaults.php"); | ||
| 22 | // ------------------------------- | 22 | // ------------------------------- |
| 23 | // page start | 23 | // page start |
| 24 | // ------------------------------- | 24 | // ------------------------------- |
| 25 | - | 25 | +//echo $_SERVER["QUERY_STRING"]; |
| 26 | // check the session, but don't redirect if the check fails | 26 | // check the session, but don't redirect if the check fails |
| 27 | if (checkSessionAndRedirect(false)) { | 27 | if (checkSessionAndRedirect(false)) { |
| 28 | - // session check succeeds, so default action should be the dashboard if no action was specified | ||
| 29 | - if (!isset($action)) { | ||
| 30 | - $action = "dashboard"; | ||
| 31 | - } | ||
| 32 | -} else { | 28 | + //get around the problem with search |
| 29 | + if (strcmp($fForStandardSearch, "yes") == 0) { | ||
| 30 | + $action = "standardSearch"; | ||
| 31 | + } else if (!isset($action)) { | ||
| 32 | + // session check succeeds, so default action should be the dashboard if no action was specified | ||
| 33 | + $action = "dashboard"; | ||
| 34 | + } | ||
| 35 | +} else { | ||
| 33 | // session check fails, so default action should be the login form if no action was specified | 36 | // session check fails, so default action should be the login form if no action was specified |
| 34 | if (!isset($action)) { | 37 | if (!isset($action)) { |
| 35 | $action = "loginForm"; | 38 | $action = "loginForm"; |
| @@ -39,6 +42,7 @@ if (checkSessionAndRedirect(false)) { | @@ -39,6 +42,7 @@ if (checkSessionAndRedirect(false)) { | ||
| 39 | // need to strip query string params from action before attempting to retrieve from sitemap | 42 | // need to strip query string params from action before attempting to retrieve from sitemap |
| 40 | 43 | ||
| 41 | // check for the presence of additional params | 44 | // check for the presence of additional params |
| 45 | +//echo $_SERVER["QUERY_STRING"]; | ||
| 42 | if (strstr($_SERVER["QUERY_STRING"], "&")) { | 46 | if (strstr($_SERVER["QUERY_STRING"], "&")) { |
| 43 | // strip and save the querystring | 47 | // strip and save the querystring |
| 44 | $queryString = substr($_SERVER["QUERY_STRING"], strpos($_SERVER["QUERY_STRING"], "&")+1, strlen($_SERVER["QUERY_STRING"])); | 48 | $queryString = substr($_SERVER["QUERY_STRING"], strpos($_SERVER["QUERY_STRING"], "&")+1, strlen($_SERVER["QUERY_STRING"])); |