[Mapbender-commits] r9709 - trunk/mapbender/http_auth/http

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Wed Mar 22 06:16:35 PDT 2017


Author: armin11
Date: 2017-03-22 06:16:35 -0700 (Wed, 22 Mar 2017)
New Revision: 9709

Modified:
   trunk/mapbender/http_auth/http/index.php
Log:
First draft to also parse ows post queries - needed for wfs clients!

Modified: trunk/mapbender/http_auth/http/index.php
===================================================================
--- trunk/mapbender/http_auth/http/index.php	2017-03-22 13:06:03 UTC (rev 9708)
+++ trunk/mapbender/http_auth/http/index.php	2017-03-22 13:16:35 UTC (rev 9709)
@@ -24,6 +24,7 @@
 require_once(dirname(__FILE__) . "/../../http/classes/class_mb_exception.php");
 require(dirname(__FILE__) . "/../../owsproxy/http/classes/class_QueryHandler.php");
 $urlsToExclude = array();
+$postData = false;
 if (is_file(dirname(__FILE__) . "/../../conf/excludeproxyurls.conf"))
 {
     require_once(dirname(__FILE__) . "/../../conf/excludeproxyurls.conf");
@@ -98,7 +99,14 @@
 //let's do the proxy things (came from owsproxy.php):
 //special for type of authentication ******************************
 
-$postdata = $HTTP_RAW_POST_DATA;
+//test for existing post data
+$postData = file_get_contents("php://input");
+if (isset($postData) && $postData !== '') {
+	
+} else {
+	$postData = false;
+}
+
 $layerId = $_REQUEST['layer_id'];
 $wfsId = $_REQUEST['wfs_id'];
 //new option for nested layers
@@ -107,7 +115,7 @@
     $withChilds = true;
 }
 
-$query = new QueryHandler();
+$query = new QueryHandler($postData);
 
 // an array with keys and values toLoserCase -> caseinsensitiv
 $reqParams = $query->getRequestParams();



More information about the Mapbender_commits mailing list