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

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Mon May 3 06:28:08 EDT 2010


Author: christoph
Date: 2010-05-03 06:28:08 -0400 (Mon, 03 May 2010)
New Revision: 6058

Modified:
   trunk/mapbender/http/classes/class_wms.php
Log:


Modified: trunk/mapbender/http/classes/class_wms.php
===================================================================
--- trunk/mapbender/http/classes/class_wms.php	2010-05-03 10:20:58 UTC (rev 6057)
+++ trunk/mapbender/http/classes/class_wms.php	2010-05-03 10:28:08 UTC (rev 6058)
@@ -2550,6 +2550,16 @@
 		}
 	}
 	
+	public static function getWmsIdByLayerId ($id) {
+		$sql = "SELECT DISTINCT fkey_wms_id FROM layer WHERE layer_id = $1";
+		$res = db_prep_query($sql, array($id), array("i"));
+		$row = db_fetch_assoc($res);
+		if ($row) {
+			return $row["fkey_wms_id"];
+		}
+		return null;
+	}
+	
 	/**
 	 * Selects all WMS of the current user from the database.
 	 * Then it creates the corresponding WMS object and returns



More information about the Mapbender_commits mailing list