[Mapbender-commits] r10128 - trunk/mapbender/http/php
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Mon May 20 06:08:24 PDT 2019
Author: armin11
Date: 2019-05-20 06:08:24 -0700 (Mon, 20 May 2019)
New Revision: 10128
Modified:
trunk/mapbender/http/php/mod_sessionWrapper.php
Log:
Fix for different hostnames
Modified: trunk/mapbender/http/php/mod_sessionWrapper.php
===================================================================
--- trunk/mapbender/http/php/mod_sessionWrapper.php 2019-05-17 08:57:42 UTC (rev 10127)
+++ trunk/mapbender/http/php/mod_sessionWrapper.php 2019-05-20 13:08:24 UTC (rev 10128)
@@ -12,7 +12,8 @@
$resultObj['success'] = false;
$resultObj['message'] = 'no message';
-if (!($hostName !== 'localhost' or $hostName !== '127.0.0.1')) {
+//if (!($hostName == '127.0.0.1')) {
+if (!($hostName == 'localhost' or $hostName == '127.0.0.1')) {
$resultObj['message'] ='hostName not allowed - only local connections possible (localhost,127.0.0.1)';
$resultObj['result'] = null;
echo json_encode($resultObj);
@@ -22,7 +23,7 @@
if (isset($_REQUEST["sessionId"]) & $_REQUEST["sessionId"] != "") {
//echo "<br>Requested sessionId: ".$_REQUEST["sessionId"]."<br>";
} else {
- $resultObj['message'] ='No sessioId given - please give parameter!';
+ $resultObj['message'] ='No sessionId given - please give parameter!';
$resultObj['result'] = null;
echo json_encode($resultObj);
die();
@@ -30,6 +31,8 @@
$existSession = Mapbender::session()->storageExists($_REQUEST["sessionId"]);
if ($existSession) {
$e = new mb_notice("storage exists");
+ //grabb session!
+ session_id($_REQUEST["sessionId"]);
} else {
$e = new mb_exception("storage does not exist!");
$resultObj['message'] ='Requested session does not exists on server - please use existing identifier!';
@@ -93,7 +96,7 @@
echo json_encode($resultObj);
die();
}*/
- $value = $testMatch;
+ $value = urldecode($testMatch);
$testMatch = NULL;
} else {
//generate dummy gml and put it into session:
More information about the Mapbender_commits
mailing list