[Mapbender-commits] r7047 - trunk/mapbender/http/plugins

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Mon Oct 18 10:46:25 EDT 2010


Author: christoph
Date: 2010-10-18 07:46:25 -0700 (Mon, 18 Oct 2010)
New Revision: 7047

Modified:
   trunk/mapbender/http/plugins/ol_wms.php
Log:
openlayers: set max extent to extent of first wms

Modified: trunk/mapbender/http/plugins/ol_wms.php
===================================================================
--- trunk/mapbender/http/plugins/ol_wms.php	2010-10-18 14:24:59 UTC (rev 7046)
+++ trunk/mapbender/http/plugins/ol_wms.php	2010-10-18 14:46:25 UTC (rev 7047)
@@ -55,12 +55,14 @@
 		for ($i = 0; $i < count($mywms->objLayer[0]->layer_epsg); $i++) {
 			$rootLayerEpsg = $mywms->objLayer[0]->layer_epsg[$i];
 			if ($rootLayerEpsg["epsg"] === "EPSG:4326") {
+				echo "console.log(ol_map.maxExtent);";
 				echo "ol_map.setOptions({maxExtent: new OpenLayers.Bounds(" .
 					$rootLayerEpsg["minx"] . "," .
 					$rootLayerEpsg["miny"] . "," .
 					$rootLayerEpsg["maxx"] . "," .
 					$rootLayerEpsg["maxy"] .
 				")});";
+				echo "console.log(ol_map.maxExtent);";
 			}
 		}
 	}



More information about the Mapbender_commits mailing list