diff --git a/webfrontend/index.php b/webfrontend/index.php index abbc2c2..3d14d5a 100644 --- a/webfrontend/index.php +++ b/webfrontend/index.php @@ -34,6 +34,7 @@ $showLoginForm = false; $showSuccess = false; $showFailure = false; + $showTokenForm = false; $isApi = false; $pIp = $_SERVER[ 'REMOTE_ADDR' ]; @@ -74,12 +75,12 @@ } else { // This is done by apache mod_rewrite - $pToken = $_GET[ 'token' ]; - $lToken = preg_replace( '/[^0-9a-fA-F]/i', "", $pToken ); + $pToken = $_GET['token']; + $lToken = $str= ltrim ($pToken, '/'); - if(strlen($lToken) != 16) { - $showFailure = true; - $failureMsg = "Please provide Token"; + if(strlen($lToken) == 0) { + $showLoginForm = true; + $showTokenForm = true; } else { $showLoginForm = true; } @@ -127,18 +128,24 @@ if ($isApi == false) { } - +
+ + + + + + + + + - - -