svn commit: r975 - trunk/mapbender/http/javascripts/map.php

christoph at osgeo.org christoph at osgeo.org
Mon Dec 11 06:03:49 EST 2006


Author: christoph
Date: 2006-12-11 11:03:49+0000
New Revision: 975

Modified:
   trunk/mapbender/http/javascripts/map.php

Log:
* added function mb_ajax_post
* added wfs subfunctions
   - read
   - write
   - init

Modified: trunk/mapbender/http/javascripts/map.php
Url: https://mapbender.osgeo.org/source/browse/mapbender/trunk/mapbender/http/javascripts/map.php?view=diff&rev=975&p1=trunk/mapbender/http/javascripts/map.php&p2=trunk/mapbender/http/javascripts/map.php&r1=974&r2=975
==============================================================================
--- trunk/mapbender/http/javascripts/map.php	(original)
+++ trunk/mapbender/http/javascripts/map.php	2006-12-11 11:03:49+0000
@@ -49,7 +49,9 @@
 var mb_log = null;
 
 var mb_MapRequestSubFunctions = new Array();
-var mb_WfsRequestSubFunctions = new Array();
+var mb_WfsInitSubFunctions = new Array();
+var mb_WfsReadSubFunctions = new Array();
+var mb_WfsWriteSubFunctions = new Array();
 var mb_MapRequestPreFunctions = new Array();
 var mb_FeatureInfoPreFunctions = new Array();
 var mb_PanSubElements = new Array();
@@ -58,6 +60,7 @@
 var mb_GetScalePreFunctions = new Array();
 var mb_vendorSpecific = new Array();
 var mb_loadWmsSubFunctions = new Array();
+var mb_security_proxy = "http://wms1.ccgis.de/mapbender/tools/security_proxy.php?mb_ows_security_proxy=";
 
 <?php
 echo "var mb_nr = '".session_id()."';";
@@ -79,6 +82,15 @@
 		alert(e);
 	}
 }	
+
+function mb_ajax_post(url, param, callback) {
+	try {
+		mb_ajaxWrap_post(url, param, callback);
+	}
+	catch(e) {
+		alert(e);
+	}
+}	
 	
 function init(){
 	for(var i=0; i<mb_InitFunctions.length; i++){
@@ -105,8 +117,14 @@
 function mb_registerSubFunctions(stringFunction){
 	mb_MapRequestSubFunctions[mb_MapRequestSubFunctions.length] = stringFunction;
 }
-function mb_registerWfsSubFunctions(stringFunction){
-	mb_WfsRequestSubFunctions[mb_WfsRequestSubFunctions.length] = stringFunction;
+function mb_registerWfsInitSubFunctions(stringFunction){
+	mb_WfsInitSubFunctions[mb_WfsInitSubFunctions.length] = stringFunction;
+}
+function mb_registerWfsReadSubFunctions(stringFunction){
+	mb_WfsReadSubFunctions[mb_WfsReadSubFunctions.length] = stringFunction;
+}
+function mb_registerWfsWriteSubFunctions(stringFunction){
+	mb_WfsWriteSubFunctions[mb_WfsWriteSubFunctions.length] = stringFunction;
 }
 function mb_registerMapObj(frameName, elementName,wms_index,width, height){
 	mb_mapObj[mb_mapObj.length] = new mb_mapObj_const(frameName, elementName, width, height, wms_index);    
@@ -999,7 +1017,7 @@
 function mb_disableThisButton(elName){
    for(var i=0; i<mb_button.length; i++){
       if(mb_button[i].elName == elName && mb_button[i].status == 1){
-//      		alert(mb_button[i].elName);
+      		//alert(mb_button[i].elName);
             mb_button[i].status = 0;
 		      if (mb_button[i].frameName != "") {
     	        window.frames[mb_button[i].frameName].document.getElementById(mb_button[i].elName).src = mb_button[i].img_off;
@@ -1281,6 +1299,24 @@
 	}	
 }
 
+function mb_execWfsInitSubFunctions() { 	 
+	for(var i=0; i<mb_WfsInitSubFunctions.length; i++){ 	 
+		mb_WfsInitSubFunctions[i](); 	 
+	} 	 
+}
+
+function mb_execWfsReadSubFunctions(geom) { 	 
+	for(var i=0; i<mb_WfsReadSubFunctions.length; i++){ 	 
+		mb_WfsReadSubFunctions[i](geom); 	 
+	} 	 
+}
+
+function mb_execWfsWriteSubFunctions() { 	 
+	for(var i=0; i<mb_WfsWriteSubFunctions.length; i++){
+		mb_WfsWriteSubFunctions[i](); 	 
+	} 	 
+}
+
 function mb_getConjunctionCharacter(onlineresource){
 	if(onlineresource.indexOf("?") > -1){ 
 		if(onlineresource.charAt(onlineresource.length-1) == "?"){ 




More information about the Mapbender_commits mailing list