[Mapbender-commits] r4363 - trunk/mapbender/http/classes

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Thu Jul 16 09:41:30 EDT 2009


Author: christoph
Date: 2009-07-16 09:41:30 -0400 (Thu, 16 Jul 2009)
New Revision: 4363

Modified:
   trunk/mapbender/http/classes/class_wfs_factory.php
Log:
owsproxy and wfs

Modified: trunk/mapbender/http/classes/class_wfs_factory.php
===================================================================
--- trunk/mapbender/http/classes/class_wfs_factory.php	2009-07-16 13:41:07 UTC (rev 4362)
+++ trunk/mapbender/http/classes/class_wfs_factory.php	2009-07-16 13:41:30 UTC (rev 4363)
@@ -74,6 +74,13 @@
 		$res = db_prep_query($sql, $v, $t);
 		$cnt = 0;
 		while(db_fetch_row($res)){
+			$hasOwsproxyUrl = false;
+			$e = new mb_notice("class_wfs_factory: wfs_owsproxy: ".db_result($res, $cnt, "wfs_owsproxy"));
+			if(db_result($res, $cnt, "wfs_owsproxy") != ''){
+				$owsproxyUrl = OWSPROXY."/".session_id()."/".db_result($res, $cnt, "wfs_owsproxy")."?";
+				$e = new mb_notice("class_wfs_factory: owsproxyURl: ".$owsproxyUrl);
+				$hasOwsproxyUrl = true;
+			}
 			
 			$aWfs->id = db_result($res, $cnt, "wfs_id");
 			$aWfs->name = db_result($res, $cnt, "wfs_name");
@@ -82,9 +89,21 @@
 			$aWfs->getCapabilities = db_result($res, $cnt, "wfs_getcapabilities");
 			$aWfs->getCapabilitiesDoc = db_result($res, $cnt, "wfs_getcapabilities_doc");
 			$aWfs->uploadUrl = db_result($res, $cnt, "wfs_upload_url");
-			$aWfs->describeFeatureType = db_result($res, $cnt, "wfs_describefeaturetype");
-			$aWfs->getFeature = db_result($res, $cnt, "wfs_getfeature");
-			$aWfs->transaction = db_result($res, $cnt, "wfs_transaction");
+			$aWfs->describeFeatureType = db_result($res, $cnt, "wfs_describefeaturetype");			
+			if(!$hasOwsproxyUrl){
+				$aWfs->getFeature = db_result($res, $cnt, "wfs_getfeature");
+			}
+			else{
+				$aWfs->getFeature = $owsproxyUrl;
+			}
+			new mb_notice("class_wfs_factory.getFeature.url: ".$aWfs->getFeature);
+			if(!$hasOwsproxyUrl){
+				$aWfs->transaction = db_result($res, $cnt, "wfs_transaction");
+			}
+			else{
+				$aWfs->transaction = $owsproxyUrl;
+			}
+						
 			$aWfs->fees = db_result($res, $cnt, "fees");
 			$aWfs->accessconstraints = db_result($res, $cnt, "accessconstraints");
 			$aWfs->owner = db_result($res, $cnt, "wfs_owner");
@@ -146,4 +165,4 @@
 		return $aWfs;	
 	}
 }
-?>
\ No newline at end of file
+?>



More information about the Mapbender_commits mailing list