[Mapbender-commits] r8625 - in trunk/mapbender/http/extensions/mobilemap: _build js js/dev mod_mapbender query query/mapserver query/mapserver/dhm_rlp

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Wed May 22 07:44:11 PDT 2013


Author: armin11
Date: 2013-05-22 07:44:11 -0700 (Wed, 22 May 2013)
New Revision: 8625

Added:
   trunk/mapbender/http/extensions/mobilemap/query/mapserver/
   trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm.map
   trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm_rlp/
   trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm_rlp/dhm.rlp.tfw
   trunk/mapbender/http/extensions/mobilemap/query/mapserver/wms_dhm_template.map
   trunk/mapbender/http/extensions/mobilemap/query/rasterqueryWms.php
Modified:
   trunk/mapbender/http/extensions/mobilemap/_build/ngms_event.js
   trunk/mapbender/http/extensions/mobilemap/_build/ngms_event.min.js
   trunk/mapbender/http/extensions/mobilemap/js/dev/1_ngms_olextent.js
   trunk/mapbender/http/extensions/mobilemap/js/ngms_event.min.js
   trunk/mapbender/http/extensions/mobilemap/mod_mapbender/search.js
   trunk/mapbender/http/extensions/mobilemap/query/rasterquery.php
Log:
New possibility to integrate a wms raster resource to get height information for the mobilemap extension.

Modified: trunk/mapbender/http/extensions/mobilemap/_build/ngms_event.js
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/_build/ngms_event.js	2013-05-21 16:02:37 UTC (rev 8624)
+++ trunk/mapbender/http/extensions/mobilemap/_build/ngms_event.js	2013-05-22 14:44:11 UTC (rev 8625)
@@ -52,7 +52,7 @@
 			)
 		]);	
 	  
-	  //Default Koordinatenabfrage / Rasterquery
+	  //Default Koordinatenabfrage / Rasterquery / RasterqueryWms
 	  if(querylayer == "dhm"){
 		  setMarkerhint(window.lang.convert('Meldung:'),window.lang.convert('bitte warten...'));
 		  var featureurl = 'query/rasterquery.php?'
@@ -61,6 +61,15 @@
 		  loadFeature(featureurl);	
 			//alert("Um eine Ebene abzufragen selektieren Sie bitte unter Abfrage --> Abfrageebene w\u00e4hlen die gew\u00fcnschte Ebenen aus!");
 	  }
+	  else if(querylayer == "dhmWms"){
+		  setMarkerhint(window.lang.convert('Meldung:'),window.lang.convert('bitte warten...'));
+		  var featureurl = 'query/rasterqueryWms.php?'
+			+ 'coord=' + lonlat.lon + ', ' + lonlat.lat
+			+ '&lang=' + actuallang;
+		 // alert("lon: "+lonlat.lon+" - lat: ".lonlat.lat);
+		  //loadFeature(featureurl);	
+	//alert("Um eine Ebene abzufragen selektieren Sie bitte unter Abfrage --> Abfrageebene w\u00e4hlen die gew\u00fcnschte Ebenen aus!");
+	  }
 	  else if(querylayer == "pois"){
 		var activepoilayer = poilayer.params.LAYERS;
 	  	var featureurl = 'query/poiquery.php?'
@@ -99,7 +108,7 @@
 	//Abfrageebene darstellen
 	showQuerylayer: function(){
 	  var querylayer = $('#queryselect').val();
-	  if(querylayer == "dhm"){
+	  if(querylayer == "dhm" || querylayer == "dhmWms"){
 	  setMarkerhint(window.lang.convert('Standardabfrage:'),window.lang.convert('Koordinaten + Hoehe'));
 	  }
 	  else{
@@ -114,7 +123,7 @@
 //Abfrageebene darstellen
 function showQuerylayer(){
 	  var querylayer = $('#queryselect').val();
-	  if(querylayer == "dhm"){
+	  if(querylayer == "dhm" ||  querylayer == "dhmWms"){
 	   setMarkerhint(window.lang.convert('Standardabfrage:'),window.lang.convert('Koordinaten + Hoehe'));
 	  }
 	  else{
@@ -130,9 +139,9 @@
 		url: myurl,
 		//data: {layers:mylayers,imgsize:myimgsize},
 		success: function(ergebnis){
-					alert(myurl);
+					//alert(myurl);
 					if(ergebnis){
-						alert(ergebnis);
+						//alert(ergebnis);
 						if(ergebnis.length < 5){
 							ergebnis = window.lang.convert('Kein Ergebnis!');
 						}
@@ -661,11 +670,17 @@
 			} else {
 				var fiPopUp = false; 
 			}	
-			if (fiPopUp) {
+		
+			if (fiPopUp == true ) {
 				setMarkerhint(window.lang.convert('Meldung:'),window.lang.convert('bitte warten...'));
 			} else {
-				$.mobile.changePage($("#featureinforesult"),pageTransition);
-				$("#ficontentdiv").text(window.lang.convert("Bitte warten..."));
+				if (querylayer.length == 0) {
+					//featureInfo on dhm
+					setMarkerhint(window.lang.convert('Meldung:'),window.lang.convert('bitte warten...'));
+				} else {
+					$.mobile.changePage($("#featureinforesult"),pageTransition);
+					$("#ficontentdiv").text(window.lang.convert("Bitte warten..."));
+				}
 			}
 			//
 	 		if(querylayer.length>0){
@@ -700,7 +715,9 @@
 				}
 			} else {
 				// Standardabfrage, falls keiner ausgewählt ist
-				var featureurl = 'query/rasterquery.php?coord='+lonlat.lon+ ', '+lonlat.lat+'&lang='+actuallang;
+				//d.h. dhm!
+				var featureurl = 'query/rasterqueryWms.php?coord='+lonlat.lon+ ', '+lonlat.lat+'&lang='+actuallang;
+				//alert(featureurl);
 				loadFeature(featureurl);	
 			}
 	 	},

Modified: trunk/mapbender/http/extensions/mobilemap/_build/ngms_event.min.js
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/_build/ngms_event.min.js	2013-05-21 16:02:37 UTC (rev 8624)
+++ trunk/mapbender/http/extensions/mobilemap/_build/ngms_event.min.js	2013-05-22 14:44:11 UTC (rev 8625)
@@ -1,8 +1,8 @@
 OpenLayers.Control.Click=OpenLayers.Class(OpenLayers.Control,{defaultHandlerOptions:{single:!0,pixelTolerance:0,stopSingle:!1},initialize:function(a){this.handlerOptions=OpenLayers.Util.applyDefaults((a||{}).handlerOptions||{},this.defaultHandlerOptions);OpenLayers.Control.prototype.initialize.apply(this,arguments);this.handler=new OpenLayers.Handler.Click(this,{click:this.onClick},this.handlerOptions)},onClick:function(a){var b=map.getLonLatFromViewPortPx(a.xy),c=$("#queryselect").val(),d=$("#select-lang").val(),
-e=new OpenLayers.Geometry.Point(b.lon,b.lat),f=new OpenLayers.Geometry.Point(b.lon,b.lat);vector_marker.removeAllFeatures();vector_marker.addFeatures([new OpenLayers.Feature.Vector(e,{},olSearchSymbol),new OpenLayers.Feature.Vector(f,{},olFeaturequerySymbol)]);"dhm"==c?(setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")),a="query/rasterquery.php?coord="+b.lon+", "+b.lat+"&lang="+d):"pois"==c?a="query/poiquery.php?qx="+b.lon+"&qy="+b.lat+"&qlayer="+poilayer.params.LAYERS+
-"&qextent="+map.getExtent().toBBOX()+"&qsize="+map.size.w+" "+map.size.h+"&lang="+d:(setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")),a="query/proxy.php?wms=SERVICE=WMS&REQUEST=getFeatureInfo&VERSION=1.1.1&mapfile="+c+"&layers="+c+"&QUERY_LAYERS="+c+"&SRS="+featurequerySrc+"&BBOX="+map.getExtent().toBBOX()+"&WIDTH="+map.size.w+"&HEIGHT="+map.size.h+"&X="+a.xy.x+"&Y="+a.xy.y+"&INFO_FORMAT=text/html");loadFeature(a)},showQuerylayer:function(){var a=$("#queryselect").val();
-"dhm"==a?setMarkerhint(window.lang.convert("Standardabfrage:"),window.lang.convert("Koordinaten + Hoehe")):setMarkerhint(window.lang.convert("aktuelle Abfrageebene:"),a)},CLASS_NAME:"OpenLayers.Control.Click"});function showQuerylayer(){var a=$("#queryselect").val();"dhm"==a?setMarkerhint(window.lang.convert("Standardabfrage:"),window.lang.convert("Koordinaten + Hoehe")):setMarkerhint(window.lang.convert("aktuelle Abfrageebene:"),a)}
-function loadFeature(a){$.ajax({type:"GET",url:a,success:function(b){alert(a);b&&(alert(b),5>b.length&&(b=window.lang.convert("Kein Ergebnis!")),setMarkerhint(window.lang.convert("Abfrageergebnis:"),b))}})}
+e=new OpenLayers.Geometry.Point(b.lon,b.lat),f=new OpenLayers.Geometry.Point(b.lon,b.lat);vector_marker.removeAllFeatures();vector_marker.addFeatures([new OpenLayers.Feature.Vector(e,{},olSearchSymbol),new OpenLayers.Feature.Vector(f,{},olFeaturequerySymbol)]);"dhm"==c?(setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")),a="query/rasterquery.php?coord="+b.lon+", "+b.lat+"&lang="+d,loadFeature(a)):"dhmWms"==c?setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")):
+("pois"==c?a="query/poiquery.php?qx="+b.lon+"&qy="+b.lat+"&qlayer="+poilayer.params.LAYERS+"&qextent="+map.getExtent().toBBOX()+"&qsize="+map.size.w+" "+map.size.h+"&lang="+d:(setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")),a="query/proxy.php?wms=SERVICE=WMS&REQUEST=getFeatureInfo&VERSION=1.1.1&mapfile="+c+"&layers="+c+"&QUERY_LAYERS="+c+"&SRS="+featurequerySrc+"&BBOX="+map.getExtent().toBBOX()+"&WIDTH="+map.size.w+"&HEIGHT="+map.size.h+"&X="+a.xy.x+"&Y="+a.xy.y+
+"&INFO_FORMAT=text/html"),loadFeature(a))},showQuerylayer:function(){var a=$("#queryselect").val();"dhm"==a||"dhmWms"==a?setMarkerhint(window.lang.convert("Standardabfrage:"),window.lang.convert("Koordinaten + Hoehe")):setMarkerhint(window.lang.convert("aktuelle Abfrageebene:"),a)},CLASS_NAME:"OpenLayers.Control.Click"});
+function showQuerylayer(){var a=$("#queryselect").val();"dhm"==a||"dhmWms"==a?setMarkerhint(window.lang.convert("Standardabfrage:"),window.lang.convert("Koordinaten + Hoehe")):setMarkerhint(window.lang.convert("aktuelle Abfrageebene:"),a)}function loadFeature(a){$.ajax({type:"GET",url:a,success:function(a){a&&(5>a.length&&(a=window.lang.convert("Kein Ergebnis!")),setMarkerhint(window.lang.convert("Abfrageergebnis:"),a))}})}
 OpenLayers.Control.ScaleLine=OpenLayers.Class(OpenLayers.Control,{maxWidth:100,topOutUnits:"km",topInUnits:"m",bottomOutUnits:"mi",bottomInUnits:"ft",eTop:null,eBottom:null,geodesic:!1,draw:function(){OpenLayers.Control.prototype.draw.apply(this,arguments);this.eTop||(this.eTop=document.createElement("div"),this.eTop.className=this.displayClass+"Top",this.div.appendChild(this.eTop),this.eTop.style.visibility=""==this.topOutUnits||""==this.topInUnits?"hidden":"visible",this.eBottom=document.createElement("div"),
 this.eBottom.className=this.displayClass+"Bottom",this.div.appendChild(this.eBottom),this.eBottom.style.visibility=""==this.bottomOutUnits||""==this.bottomInUnits?"hidden":"visible");this.map.events.register("moveend",this,this.update);this.update();return this.div},getBarLen:function(a){var b=parseInt(Math.log(a)/Math.log(10)),b=Math.pow(10,b),a=parseInt(a/b);return(5<a?5:2<a?2:1)*b},update:function(){var a=this.map.getResolution();if(a){var b=this.map.getUnits(),c=OpenLayers.INCHES_PER_UNIT,d=this.maxWidth*
 a*c[b],e=1;!0===this.geodesic&&(e=(this.map.getGeodesicPixelSize().w||1.0E-6)*this.maxWidth/(d/c.km),d*=e);var f,g;1E5<d?(f=this.topOutUnits,g=this.bottomOutUnits):(f=this.topInUnits,g=this.bottomInUnits);var h=d/c[f],j=d/c[g],d=this.getBarLen(h),j=this.getBarLen(j),h=d/c[b]*c[f],j=j/c[b]*c[g],b=h/a/e,a=j/a/e;"visible"==this.eBottom.style.visibility&&(this.eBottom.style.width=Math.round(a)+"px");"visible"==this.eTop.style.visibility&&(this.eTop.style.width=Math.round(b)+"px",this.eTop.innerHTML=d+
@@ -22,10 +22,10 @@
 c.append($("<div>",{"class":"icon layer_visibility layer_checked",text:" "}).click(function(){switchVisibility($(this).parent())}));c.append($("<div>",{"class":"icon move arrow_up",text:" "}).click(function(){up(a)}));h=$('<div class="collapsible unselected" data-role="collapsible" data-collapsed="true" data-theme="a" data-content-theme="c" data-inset="true"></div>');h.append("<h3>"+b+"</h3>");var j=$("<table></table>"),m=$("<tr></tr>"),n=$('<td class="layerinfo"></td>');g&&n.append($("<div>",{"class":"icon layer_preview",
 text:" "}).click(function(){zoomToBbox(k);$.mobile.changePage($("#mappage"),pageTransition)}));n.append("</br><p>"+l+"%</p>");g=$("<td></td>");g.append("<p><b>"+e+"</b></p><p>"+f+"</p>");g.append("<p><b>"+b+"</b></p><p>"+d+"</p>");m.append(n);m.append(g);j.append(m);h.append(j);c.append(h);return c}var maxlayers=5,maxresults=40,baseinfo=[];searchUrl="mod_mapbender/search_proxy.php?languageCode=de&resultTarget=web&maxResults="+maxresults;
 function addmyLayer(){OpenLayers.Control.Click=OpenLayers.Class(OpenLayers.Control,{defaultHandlerOptions:{single:!0,pixelTolerance:0,stopSingle:!1},initialize:function(a){this.handlerOptions=OpenLayers.Util.applyDefaults((a||{}).handlerOptions||{},this.defaultHandlerOptions);OpenLayers.Control.prototype.initialize.apply(this,arguments);this.handler=new OpenLayers.Handler.Click(this,{click:this.onClick},this.handlerOptions)},onClick:function(a){var b=map.getLonLatFromViewPortPx(a.xy),c=$("#ownlist").find(".query_checked").parent(),
-d=$("#select-lang").val(),e=new OpenLayers.Geometry.Point(b.lon,b.lat),f=new OpenLayers.Geometry.Point(b.lon,b.lat);vector_marker.removeAllFeatures();vector_marker.addFeatures([new OpenLayers.Feature.Vector(e,{},olSearchSymbol),new OpenLayers.Feature.Vector(f,{},olFeaturequerySymbol)]);(e="p"===$("#select-feature-info").val()?!0:!1)?setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")):($.mobile.changePage($("#featureinforesult"),pageTransition),$("#ficontentdiv").text(window.lang.convert("Bitte warten...")));
-0<c.length?(a=c.attr("getmapurl")+"&SERVICE=WMS&REQUEST=getFeatureInfo&VERSION=1.1.1&mapfile="+c.attr("name")+"&layers="+c.attr("name")+"&QUERY_LAYERS="+c.attr("name")+"&SRS="+featurequerySrc+"&BBOX="+map.getExtent().toBBOX()+"&WIDTH="+map.size.w+"&HEIGHT="+map.size.h+"&X="+a.xy.x+"&Y="+a.xy.y+"&INFO_FORMAT=text/html&FORMAT=image/png&STYLES=",e?(a=$('<iframe src="'+a+'" class="query_iframe"><p>Die Abfrage kann leider nicht angezeigt werden.</p></img>'),setMarkerhint("Abfrageergebnis:",a)):(a=$('<iframe src="'+
-a+'" class="query_iframe_full"><p>Die Abfrage kann leider nicht angezeigt werden.</p></img>'),$("#ficontentdiv").text(""),$("#ficontentdiv").append(a))):(a="query/rasterquery.php?coord="+b.lon+", "+b.lat+"&lang="+d,loadFeature(a))},CLASS_NAME:"OpenLayers.Control.Click"});$("#mapbenderbut").click(function(){$.mobile.changePage($("#mod_mapbender"),pageTransition);refresh()});$("#mapbendersearchformbut").click(function(){searchMaps(searchUrl+"&searchText="+$("#mapbendersearchfield").val())});$("#mapbendersearchfield").live("keypress",
-function(a){13===a.keyCode&&searchMaps(searchUrl+"&searchText="+$("#mapbendersearchfield").val())});$("div[data-role=collapsible]").live("expand",function(){$("div[data-role=collapsible]").not($(this)).trigger("collapse")});$(".addToMapBut").click(function(){$("div[data-role=collapsible]").not(".ui-collapsible-collapsed").trigger("collapse");$.mobile.changePage($("#mappage"),pageTransition)});addBaselayers()}
+d=$("#select-lang").val(),e=new OpenLayers.Geometry.Point(b.lon,b.lat),f=new OpenLayers.Geometry.Point(b.lon,b.lat);vector_marker.removeAllFeatures();vector_marker.addFeatures([new OpenLayers.Feature.Vector(e,{},olSearchSymbol),new OpenLayers.Feature.Vector(f,{},olFeaturequerySymbol)]);e="p"===$("#select-feature-info").val()?!0:!1;!0==e?setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")):0==c.length?setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")):
+($.mobile.changePage($("#featureinforesult"),pageTransition),$("#ficontentdiv").text(window.lang.convert("Bitte warten...")));0<c.length?(a=c.attr("getmapurl")+"&SERVICE=WMS&REQUEST=getFeatureInfo&VERSION=1.1.1&mapfile="+c.attr("name")+"&layers="+c.attr("name")+"&QUERY_LAYERS="+c.attr("name")+"&SRS="+featurequerySrc+"&BBOX="+map.getExtent().toBBOX()+"&WIDTH="+map.size.w+"&HEIGHT="+map.size.h+"&X="+a.xy.x+"&Y="+a.xy.y+"&INFO_FORMAT=text/html&FORMAT=image/png&STYLES=",e?(a=$('<iframe src="'+a+'" class="query_iframe"><p>Die Abfrage kann leider nicht angezeigt werden.</p></img>'),
+setMarkerhint("Abfrageergebnis:",a)):(a=$('<iframe src="'+a+'" class="query_iframe_full"><p>Die Abfrage kann leider nicht angezeigt werden.</p></img>'),$("#ficontentdiv").text(""),$("#ficontentdiv").append(a))):(a="query/rasterqueryWms.php?coord="+b.lon+", "+b.lat+"&lang="+d,loadFeature(a))},CLASS_NAME:"OpenLayers.Control.Click"});$("#mapbenderbut").click(function(){$.mobile.changePage($("#mod_mapbender"),pageTransition);refresh()});$("#mapbendersearchformbut").click(function(){searchMaps(searchUrl+
+"&searchText="+$("#mapbendersearchfield").val())});$("#mapbendersearchfield").live("keypress",function(a){13===a.keyCode&&searchMaps(searchUrl+"&searchText="+$("#mapbendersearchfield").val())});$("div[data-role=collapsible]").live("expand",function(){$("div[data-role=collapsible]").not($(this)).trigger("collapse")});$(".addToMapBut").click(function(){$("div[data-role=collapsible]").not(".ui-collapsible-collapsed").trigger("collapse");$.mobile.changePage($("#mappage"),pageTransition)});addBaselayers()}
 function preview(a,b,c){$.ajax({previewurl:a,layerid:b,bbox:c,success:function(){$("#preview").find("div[data-role=content]").empty();$("#preview").find("div[data-role=content]").append('<img src="'+$(this).attr("previewurl")+'" alt="image" style="width:200px;">');var a=$(this).attr("bbox"),b=$(this).attr("layerid");$("#preview_zoom").click(function(){getOpenlayersIndex(b);zoomToBbox(a);$.mobile.changePage($("#mappage"),pageTransition)});$("#preview").popup("open")}})}
 getInfo=function(a){$("#info_content").empty();$("#info_content").append(a);$("#info").popup("open")};function getOpenlayersIndex(a){for(var b=0;b<map.layers.length;b++)if(map.layers[b].name==a)return b;return-1}function addOpenlayer(a,b,c){a=new OpenLayers.Layer.WMS(a,c,{layers:b,format:"image/png",transparent:"TRUE",transitionEffect:"resize"},{projection:mapProj,units:projUnits,opacity:0.8,singleTile:!0,isBaseLayer:!1,visibility:!0,alwaysInRange:!0});map.addLayer(a);map.setLayerIndex(a,0)}
 function removeOpenlayer(a){a=getOpenlayersIndex(a);0<=a&&map.removeLayer(map.layers[a])}function setOpenBaselayer(a){a=getOpenlayersIndex(a);0<=a&&map.setBaseLayer(map.layers[a])}function selectOpenlayer(a,b){var c=getOpenlayersIndex(a);0<=c&&map.layers[c].setVisibility(b)}

Modified: trunk/mapbender/http/extensions/mobilemap/js/dev/1_ngms_olextent.js
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/js/dev/1_ngms_olextent.js	2013-05-21 16:02:37 UTC (rev 8624)
+++ trunk/mapbender/http/extensions/mobilemap/js/dev/1_ngms_olextent.js	2013-05-22 14:44:11 UTC (rev 8625)
@@ -51,7 +51,7 @@
 			)
 		]);	
 	  
-	  //Default Koordinatenabfrage / Rasterquery
+	  //Default Koordinatenabfrage / Rasterquery / RasterqueryWms
 	  if(querylayer == "dhm"){
 		  setMarkerhint(window.lang.convert('Meldung:'),window.lang.convert('bitte warten...'));
 		  var featureurl = 'query/rasterquery.php?'
@@ -60,6 +60,15 @@
 		  loadFeature(featureurl);	
 			//alert("Um eine Ebene abzufragen selektieren Sie bitte unter Abfrage --> Abfrageebene w\u00e4hlen die gew\u00fcnschte Ebenen aus!");
 	  }
+	  else if(querylayer == "dhmWms"){
+		  setMarkerhint(window.lang.convert('Meldung:'),window.lang.convert('bitte warten...'));
+		  var featureurl = 'query/rasterqueryWms.php?'
+			+ 'coord=' + lonlat.lon + ', ' + lonlat.lat
+			+ '&lang=' + actuallang;
+		 // alert("lon: "+lonlat.lon+" - lat: ".lonlat.lat);
+		  //loadFeature(featureurl);	
+	//alert("Um eine Ebene abzufragen selektieren Sie bitte unter Abfrage --> Abfrageebene w\u00e4hlen die gew\u00fcnschte Ebenen aus!");
+	  }
 	  else if(querylayer == "pois"){
 		var activepoilayer = poilayer.params.LAYERS;
 	  	var featureurl = 'query/poiquery.php?'
@@ -98,7 +107,7 @@
 	//Abfrageebene darstellen
 	showQuerylayer: function(){
 	  var querylayer = $('#queryselect').val();
-	  if(querylayer == "dhm"){
+	  if(querylayer == "dhm" || querylayer == "dhmWms"){
 	  setMarkerhint(window.lang.convert('Standardabfrage:'),window.lang.convert('Koordinaten + Hoehe'));
 	  }
 	  else{
@@ -113,7 +122,7 @@
 //Abfrageebene darstellen
 function showQuerylayer(){
 	  var querylayer = $('#queryselect').val();
-	  if(querylayer == "dhm"){
+	  if(querylayer == "dhm" ||  querylayer == "dhmWms"){
 	   setMarkerhint(window.lang.convert('Standardabfrage:'),window.lang.convert('Koordinaten + Hoehe'));
 	  }
 	  else{
@@ -129,9 +138,9 @@
 		url: myurl,
 		//data: {layers:mylayers,imgsize:myimgsize},
 		success: function(ergebnis){
-					alert(myurl);
+					//alert(myurl);
 					if(ergebnis){
-						alert(ergebnis);
+						//alert(ergebnis);
 						if(ergebnis.length < 5){
 							ergebnis = window.lang.convert('Kein Ergebnis!');
 						}

Modified: trunk/mapbender/http/extensions/mobilemap/js/ngms_event.min.js
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/js/ngms_event.min.js	2013-05-21 16:02:37 UTC (rev 8624)
+++ trunk/mapbender/http/extensions/mobilemap/js/ngms_event.min.js	2013-05-22 14:44:11 UTC (rev 8625)
@@ -1,8 +1,8 @@
 OpenLayers.Control.Click=OpenLayers.Class(OpenLayers.Control,{defaultHandlerOptions:{single:!0,pixelTolerance:0,stopSingle:!1},initialize:function(a){this.handlerOptions=OpenLayers.Util.applyDefaults((a||{}).handlerOptions||{},this.defaultHandlerOptions);OpenLayers.Control.prototype.initialize.apply(this,arguments);this.handler=new OpenLayers.Handler.Click(this,{click:this.onClick},this.handlerOptions)},onClick:function(a){var b=map.getLonLatFromViewPortPx(a.xy),c=$("#queryselect").val(),d=$("#select-lang").val(),
-e=new OpenLayers.Geometry.Point(b.lon,b.lat),f=new OpenLayers.Geometry.Point(b.lon,b.lat);vector_marker.removeAllFeatures();vector_marker.addFeatures([new OpenLayers.Feature.Vector(e,{},olSearchSymbol),new OpenLayers.Feature.Vector(f,{},olFeaturequerySymbol)]);"dhm"==c?(setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")),a="query/rasterquery.php?coord="+b.lon+", "+b.lat+"&lang="+d):"pois"==c?a="query/poiquery.php?qx="+b.lon+"&qy="+b.lat+"&qlayer="+poilayer.params.LAYERS+
-"&qextent="+map.getExtent().toBBOX()+"&qsize="+map.size.w+" "+map.size.h+"&lang="+d:(setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")),a="query/proxy.php?wms=SERVICE=WMS&REQUEST=getFeatureInfo&VERSION=1.1.1&mapfile="+c+"&layers="+c+"&QUERY_LAYERS="+c+"&SRS="+featurequerySrc+"&BBOX="+map.getExtent().toBBOX()+"&WIDTH="+map.size.w+"&HEIGHT="+map.size.h+"&X="+a.xy.x+"&Y="+a.xy.y+"&INFO_FORMAT=text/html");loadFeature(a)},showQuerylayer:function(){var a=$("#queryselect").val();
-"dhm"==a?setMarkerhint(window.lang.convert("Standardabfrage:"),window.lang.convert("Koordinaten + Hoehe")):setMarkerhint(window.lang.convert("aktuelle Abfrageebene:"),a)},CLASS_NAME:"OpenLayers.Control.Click"});function showQuerylayer(){var a=$("#queryselect").val();"dhm"==a?setMarkerhint(window.lang.convert("Standardabfrage:"),window.lang.convert("Koordinaten + Hoehe")):setMarkerhint(window.lang.convert("aktuelle Abfrageebene:"),a)}
-function loadFeature(a){$.ajax({type:"GET",url:a,success:function(b){alert(a);b&&(alert(b),5>b.length&&(b=window.lang.convert("Kein Ergebnis!")),setMarkerhint(window.lang.convert("Abfrageergebnis:"),b))}})}
+e=new OpenLayers.Geometry.Point(b.lon,b.lat),f=new OpenLayers.Geometry.Point(b.lon,b.lat);vector_marker.removeAllFeatures();vector_marker.addFeatures([new OpenLayers.Feature.Vector(e,{},olSearchSymbol),new OpenLayers.Feature.Vector(f,{},olFeaturequerySymbol)]);"dhm"==c?(setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")),a="query/rasterquery.php?coord="+b.lon+", "+b.lat+"&lang="+d,loadFeature(a)):"dhmWms"==c?setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")):
+("pois"==c?a="query/poiquery.php?qx="+b.lon+"&qy="+b.lat+"&qlayer="+poilayer.params.LAYERS+"&qextent="+map.getExtent().toBBOX()+"&qsize="+map.size.w+" "+map.size.h+"&lang="+d:(setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")),a="query/proxy.php?wms=SERVICE=WMS&REQUEST=getFeatureInfo&VERSION=1.1.1&mapfile="+c+"&layers="+c+"&QUERY_LAYERS="+c+"&SRS="+featurequerySrc+"&BBOX="+map.getExtent().toBBOX()+"&WIDTH="+map.size.w+"&HEIGHT="+map.size.h+"&X="+a.xy.x+"&Y="+a.xy.y+
+"&INFO_FORMAT=text/html"),loadFeature(a))},showQuerylayer:function(){var a=$("#queryselect").val();"dhm"==a||"dhmWms"==a?setMarkerhint(window.lang.convert("Standardabfrage:"),window.lang.convert("Koordinaten + Hoehe")):setMarkerhint(window.lang.convert("aktuelle Abfrageebene:"),a)},CLASS_NAME:"OpenLayers.Control.Click"});
+function showQuerylayer(){var a=$("#queryselect").val();"dhm"==a||"dhmWms"==a?setMarkerhint(window.lang.convert("Standardabfrage:"),window.lang.convert("Koordinaten + Hoehe")):setMarkerhint(window.lang.convert("aktuelle Abfrageebene:"),a)}function loadFeature(a){$.ajax({type:"GET",url:a,success:function(a){a&&(5>a.length&&(a=window.lang.convert("Kein Ergebnis!")),setMarkerhint(window.lang.convert("Abfrageergebnis:"),a))}})}
 OpenLayers.Control.ScaleLine=OpenLayers.Class(OpenLayers.Control,{maxWidth:100,topOutUnits:"km",topInUnits:"m",bottomOutUnits:"mi",bottomInUnits:"ft",eTop:null,eBottom:null,geodesic:!1,draw:function(){OpenLayers.Control.prototype.draw.apply(this,arguments);this.eTop||(this.eTop=document.createElement("div"),this.eTop.className=this.displayClass+"Top",this.div.appendChild(this.eTop),this.eTop.style.visibility=""==this.topOutUnits||""==this.topInUnits?"hidden":"visible",this.eBottom=document.createElement("div"),
 this.eBottom.className=this.displayClass+"Bottom",this.div.appendChild(this.eBottom),this.eBottom.style.visibility=""==this.bottomOutUnits||""==this.bottomInUnits?"hidden":"visible");this.map.events.register("moveend",this,this.update);this.update();return this.div},getBarLen:function(a){var b=parseInt(Math.log(a)/Math.log(10)),b=Math.pow(10,b),a=parseInt(a/b);return(5<a?5:2<a?2:1)*b},update:function(){var a=this.map.getResolution();if(a){var b=this.map.getUnits(),c=OpenLayers.INCHES_PER_UNIT,d=this.maxWidth*
 a*c[b],e=1;!0===this.geodesic&&(e=(this.map.getGeodesicPixelSize().w||1.0E-6)*this.maxWidth/(d/c.km),d*=e);var f,g;1E5<d?(f=this.topOutUnits,g=this.bottomOutUnits):(f=this.topInUnits,g=this.bottomInUnits);var h=d/c[f],j=d/c[g],d=this.getBarLen(h),j=this.getBarLen(j),h=d/c[b]*c[f],j=j/c[b]*c[g],b=h/a/e,a=j/a/e;"visible"==this.eBottom.style.visibility&&(this.eBottom.style.width=Math.round(a)+"px");"visible"==this.eTop.style.visibility&&(this.eTop.style.width=Math.round(b)+"px",this.eTop.innerHTML=d+
@@ -22,10 +22,10 @@
 c.append($("<div>",{"class":"icon layer_visibility layer_checked",text:" "}).click(function(){switchVisibility($(this).parent())}));c.append($("<div>",{"class":"icon move arrow_up",text:" "}).click(function(){up(a)}));h=$('<div class="collapsible unselected" data-role="collapsible" data-collapsed="true" data-theme="a" data-content-theme="c" data-inset="true"></div>');h.append("<h3>"+b+"</h3>");var j=$("<table></table>"),m=$("<tr></tr>"),n=$('<td class="layerinfo"></td>');g&&n.append($("<div>",{"class":"icon layer_preview",
 text:" "}).click(function(){zoomToBbox(k);$.mobile.changePage($("#mappage"),pageTransition)}));n.append("</br><p>"+l+"%</p>");g=$("<td></td>");g.append("<p><b>"+e+"</b></p><p>"+f+"</p>");g.append("<p><b>"+b+"</b></p><p>"+d+"</p>");m.append(n);m.append(g);j.append(m);h.append(j);c.append(h);return c}var maxlayers=5,maxresults=40,baseinfo=[];searchUrl="mod_mapbender/search_proxy.php?languageCode=de&resultTarget=web&maxResults="+maxresults;
 function addmyLayer(){OpenLayers.Control.Click=OpenLayers.Class(OpenLayers.Control,{defaultHandlerOptions:{single:!0,pixelTolerance:0,stopSingle:!1},initialize:function(a){this.handlerOptions=OpenLayers.Util.applyDefaults((a||{}).handlerOptions||{},this.defaultHandlerOptions);OpenLayers.Control.prototype.initialize.apply(this,arguments);this.handler=new OpenLayers.Handler.Click(this,{click:this.onClick},this.handlerOptions)},onClick:function(a){var b=map.getLonLatFromViewPortPx(a.xy),c=$("#ownlist").find(".query_checked").parent(),
-d=$("#select-lang").val(),e=new OpenLayers.Geometry.Point(b.lon,b.lat),f=new OpenLayers.Geometry.Point(b.lon,b.lat);vector_marker.removeAllFeatures();vector_marker.addFeatures([new OpenLayers.Feature.Vector(e,{},olSearchSymbol),new OpenLayers.Feature.Vector(f,{},olFeaturequerySymbol)]);(e="p"===$("#select-feature-info").val()?!0:!1)?setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")):($.mobile.changePage($("#featureinforesult"),pageTransition),$("#ficontentdiv").text(window.lang.convert("Bitte warten...")));
-0<c.length?(a=c.attr("getmapurl")+"&SERVICE=WMS&REQUEST=getFeatureInfo&VERSION=1.1.1&mapfile="+c.attr("name")+"&layers="+c.attr("name")+"&QUERY_LAYERS="+c.attr("name")+"&SRS="+featurequerySrc+"&BBOX="+map.getExtent().toBBOX()+"&WIDTH="+map.size.w+"&HEIGHT="+map.size.h+"&X="+a.xy.x+"&Y="+a.xy.y+"&INFO_FORMAT=text/html&FORMAT=image/png&STYLES=",e?(a=$('<iframe src="'+a+'" class="query_iframe"><p>Die Abfrage kann leider nicht angezeigt werden.</p></img>'),setMarkerhint("Abfrageergebnis:",a)):(a=$('<iframe src="'+
-a+'" class="query_iframe_full"><p>Die Abfrage kann leider nicht angezeigt werden.</p></img>'),$("#ficontentdiv").text(""),$("#ficontentdiv").append(a))):(a="query/rasterquery.php?coord="+b.lon+", "+b.lat+"&lang="+d,loadFeature(a))},CLASS_NAME:"OpenLayers.Control.Click"});$("#mapbenderbut").click(function(){$.mobile.changePage($("#mod_mapbender"),pageTransition);refresh()});$("#mapbendersearchformbut").click(function(){searchMaps(searchUrl+"&searchText="+$("#mapbendersearchfield").val())});$("#mapbendersearchfield").live("keypress",
-function(a){13===a.keyCode&&searchMaps(searchUrl+"&searchText="+$("#mapbendersearchfield").val())});$("div[data-role=collapsible]").live("expand",function(){$("div[data-role=collapsible]").not($(this)).trigger("collapse")});$(".addToMapBut").click(function(){$("div[data-role=collapsible]").not(".ui-collapsible-collapsed").trigger("collapse");$.mobile.changePage($("#mappage"),pageTransition)});addBaselayers()}
+d=$("#select-lang").val(),e=new OpenLayers.Geometry.Point(b.lon,b.lat),f=new OpenLayers.Geometry.Point(b.lon,b.lat);vector_marker.removeAllFeatures();vector_marker.addFeatures([new OpenLayers.Feature.Vector(e,{},olSearchSymbol),new OpenLayers.Feature.Vector(f,{},olFeaturequerySymbol)]);e="p"===$("#select-feature-info").val()?!0:!1;!0==e?setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")):0==c.length?setMarkerhint(window.lang.convert("Meldung:"),window.lang.convert("bitte warten...")):
+($.mobile.changePage($("#featureinforesult"),pageTransition),$("#ficontentdiv").text(window.lang.convert("Bitte warten...")));0<c.length?(a=c.attr("getmapurl")+"&SERVICE=WMS&REQUEST=getFeatureInfo&VERSION=1.1.1&mapfile="+c.attr("name")+"&layers="+c.attr("name")+"&QUERY_LAYERS="+c.attr("name")+"&SRS="+featurequerySrc+"&BBOX="+map.getExtent().toBBOX()+"&WIDTH="+map.size.w+"&HEIGHT="+map.size.h+"&X="+a.xy.x+"&Y="+a.xy.y+"&INFO_FORMAT=text/html&FORMAT=image/png&STYLES=",e?(a=$('<iframe src="'+a+'" class="query_iframe"><p>Die Abfrage kann leider nicht angezeigt werden.</p></img>'),
+setMarkerhint("Abfrageergebnis:",a)):(a=$('<iframe src="'+a+'" class="query_iframe_full"><p>Die Abfrage kann leider nicht angezeigt werden.</p></img>'),$("#ficontentdiv").text(""),$("#ficontentdiv").append(a))):(a="query/rasterqueryWms.php?coord="+b.lon+", "+b.lat+"&lang="+d,loadFeature(a))},CLASS_NAME:"OpenLayers.Control.Click"});$("#mapbenderbut").click(function(){$.mobile.changePage($("#mod_mapbender"),pageTransition);refresh()});$("#mapbendersearchformbut").click(function(){searchMaps(searchUrl+
+"&searchText="+$("#mapbendersearchfield").val())});$("#mapbendersearchfield").live("keypress",function(a){13===a.keyCode&&searchMaps(searchUrl+"&searchText="+$("#mapbendersearchfield").val())});$("div[data-role=collapsible]").live("expand",function(){$("div[data-role=collapsible]").not($(this)).trigger("collapse")});$(".addToMapBut").click(function(){$("div[data-role=collapsible]").not(".ui-collapsible-collapsed").trigger("collapse");$.mobile.changePage($("#mappage"),pageTransition)});addBaselayers()}
 function preview(a,b,c){$.ajax({previewurl:a,layerid:b,bbox:c,success:function(){$("#preview").find("div[data-role=content]").empty();$("#preview").find("div[data-role=content]").append('<img src="'+$(this).attr("previewurl")+'" alt="image" style="width:200px;">');var a=$(this).attr("bbox"),b=$(this).attr("layerid");$("#preview_zoom").click(function(){getOpenlayersIndex(b);zoomToBbox(a);$.mobile.changePage($("#mappage"),pageTransition)});$("#preview").popup("open")}})}
 getInfo=function(a){$("#info_content").empty();$("#info_content").append(a);$("#info").popup("open")};function getOpenlayersIndex(a){for(var b=0;b<map.layers.length;b++)if(map.layers[b].name==a)return b;return-1}function addOpenlayer(a,b,c){a=new OpenLayers.Layer.WMS(a,c,{layers:b,format:"image/png",transparent:"TRUE",transitionEffect:"resize"},{projection:mapProj,units:projUnits,opacity:0.8,singleTile:!0,isBaseLayer:!1,visibility:!0,alwaysInRange:!0});map.addLayer(a);map.setLayerIndex(a,0)}
 function removeOpenlayer(a){a=getOpenlayersIndex(a);0<=a&&map.removeLayer(map.layers[a])}function setOpenBaselayer(a){a=getOpenlayersIndex(a);0<=a&&map.setBaseLayer(map.layers[a])}function selectOpenlayer(a,b){var c=getOpenlayersIndex(a);0<=c&&map.layers[c].setVisibility(b)}

Modified: trunk/mapbender/http/extensions/mobilemap/mod_mapbender/search.js
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/mod_mapbender/search.js	2013-05-21 16:02:37 UTC (rev 8624)
+++ trunk/mapbender/http/extensions/mobilemap/mod_mapbender/search.js	2013-05-22 14:44:11 UTC (rev 8625)
@@ -78,11 +78,17 @@
 			} else {
 				var fiPopUp = false; 
 			}	
-			if (fiPopUp) {
+		
+			if (fiPopUp == true ) {
 				setMarkerhint(window.lang.convert('Meldung:'),window.lang.convert('bitte warten...'));
 			} else {
-				$.mobile.changePage($("#featureinforesult"),pageTransition);
-				$("#ficontentdiv").text(window.lang.convert("Bitte warten..."));
+				if (querylayer.length == 0) {
+					//featureInfo on dhm
+					setMarkerhint(window.lang.convert('Meldung:'),window.lang.convert('bitte warten...'));
+				} else {
+					$.mobile.changePage($("#featureinforesult"),pageTransition);
+					$("#ficontentdiv").text(window.lang.convert("Bitte warten..."));
+				}
 			}
 			//
 	 		if(querylayer.length>0){
@@ -117,7 +123,9 @@
 				}
 			} else {
 				// Standardabfrage, falls keiner ausgewählt ist
-				var featureurl = 'query/rasterquery.php?coord='+lonlat.lon+ ', '+lonlat.lat+'&lang='+actuallang;
+				//d.h. dhm!
+				var featureurl = 'query/rasterqueryWms.php?coord='+lonlat.lon+ ', '+lonlat.lat+'&lang='+actuallang;
+				//alert(featureurl);
 				loadFeature(featureurl);	
 			}
 	 	},

Added: trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm.map
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm.map	                        (rev 0)
+++ trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm.map	2013-05-22 14:44:11 UTC (rev 8625)
@@ -0,0 +1,10 @@
+MAP
+NAME "test"
+LAYER # raster layer
+     NAME "mydhm"
+     DATA "dhm_rlp/dhm.rlp.tif" 
+     STATUS default
+     TYPE RASTER
+     TEMPLATE "template/query.html"
+END
+END

Added: trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm_rlp/dhm.rlp.tfw
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm_rlp/dhm.rlp.tfw	                        (rev 0)
+++ trunk/mapbender/http/extensions/mobilemap/query/mapserver/dhm_rlp/dhm.rlp.tfw	2013-05-22 14:44:11 UTC (rev 8625)
@@ -0,0 +1,6 @@
+              9.99671659
+              0.00000000
+              0.00000000
+             -9.99671659
+              288578.552
+             5650307.803

Added: trunk/mapbender/http/extensions/mobilemap/query/mapserver/wms_dhm_template.map
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/query/mapserver/wms_dhm_template.map	                        (rev 0)
+++ trunk/mapbender/http/extensions/mobilemap/query/mapserver/wms_dhm_template.map	2013-05-22 14:44:11 UTC (rev 8625)
@@ -0,0 +1,97 @@
+MAP
+  NAME 'hdm_query'
+  SIZE 1000 1000
+  UNITS meters
+  SYMBOLSET '../symbols/symbolsatkis_neu.sym'
+  FONTSET '../fonts/fonts.list'
+  EXTENT 290000 5420000 466000 5648000
+  PROJECTION
+    'init=epsg:25832'
+  END
+  IMAGECOLOR 192 192 192
+  IMAGEQUALITY 86
+
+#http://mgeospatial.wordpress.com/2010/01/16/how-to-produce-8bits-agg-homemade-colors-palette-with-mapserver/
+#OUTPUTFORMAT
+#   NAME "png8bitaggauto"
+#   DRIVER "AGG/PNG"
+#   MIMETYPE "image/png"
+#   IMAGEMODE "pc256"
+#   EXTENSION "png"
+#   FORMATOPTION "TRANSPARENT=ON"
+#   FORMATOPTION "INTERLACE=OFF"
+#   FORMATOPTION "QUANTIZE_FORCE=ON"
+#  FORMATOPTION "QUANTIZE_COLORS=256"
+#END
+
+OUTPUTFORMAT
+  NAME png
+  DRIVER AGG/PNG
+  MIMETYPE "image/png"
+  IMAGEMODE RGBA
+  EXTENSION "png"
+ FORMATOPTION "INTERLACE=OFF"
+END
+
+  LEGEND
+    IMAGECOLOR 255 255 255
+    STATUS ON
+    KEYSIZE 18 12
+    LABEL
+      TYPE BITMAP
+      SIZE MEDIUM
+      COLOR 0 0 0
+    END
+  END
+
+  WEB
+    IMAGEPATH '/data/umn/tmp/'
+    IMAGEURL '/data/umn/tmp/'
+    METADATA
+      'wms_title'           		'DHM RP Geotiff'
+      'wms_abstract' 			'DHM RP Geotiff'
+      'wms_onlineresource'  		'http://www.gdi-rp-dienste2.rlp.de/cgi-bin/mapserv.fcgi?map=/data/umn/geoportal/dhm_query/dhm.map'
+#http://www.gdi-rp-dienste2.rlp.de/cgi-bin/mapserv.fcgi?map=/data/umn/geoportal/dhm_query/dhm.map&REQUEST=GetCapabilities&VERSION=1.1.1&SERVICE=wms
+      'wms_srs'             		'EPSG:25832 EPSG:31466 EPSG:31467 EPSG:4326 EPSG:4258 EPSG:900913'
+      'wms_extent' 			'290000 5420000 466000 5648000'
+      'ows_keywordlist' 		'DHM'
+      'ows_fees' 			'none' #Gebuehren
+      'ows_accessconstraints' 		'none' #Zugriffsbeschraenkungen
+      'ows_addresstype' 		'postal'
+      'ows_address' 			'Ferdinand-Sauerbruch-Str. 15'
+      'ows_city' 			'Koblenz' 
+      'ows_stateorprovince' 		'RLP'
+      'ows_postcode' 			'56073' 
+      'ows_country' 			'Deutschland' 
+      'ows_contactperson' 		'Armin Retterath' 
+      'ows_contactinformation' 		''
+      'ows_contactorganization' 	'KGSt. GDI-RP'
+      'ows_contactposition' 		''
+      'ows_contactelectronicmailaddress''kontakt at geoportal.rlp.de'
+      'wms_contactfacsimiletelephone' 	'0261-492466'
+      'wms_contactvoicetelephone' 	'0261-492472'
+      'wms_enable_request'              '*'
+      'wms_encoding' 			'UTF-8'
+    END
+  END
+
+LAYER 
+     NAME "mydhm"
+     DATA "dhm_rlp/dhm.rlp.tif" 
+     DUMP TRUE
+     TYPE RASTER
+	TOLERANCE 0
+	TOLERANCEUNITS pixels
+	STATUS       DEFAULT
+		PROCESSING "SCALE=AUTO"
+	#PROCESSING   “BANDS=1,2,3″
+	#OFFSITE      71 74 65
+     TEMPLATE "../dhm_template.html"
+	METADATA
+		'wms_title' 'DHM Layer'
+		'wms_getfeatureinfo_formatlist' 'text/html,text/plain'
+		'gml_include_items' 'all'
+	END
+END
+
+END

Modified: trunk/mapbender/http/extensions/mobilemap/query/rasterquery.php
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/query/rasterquery.php	2013-05-21 16:02:37 UTC (rev 8624)
+++ trunk/mapbender/http/extensions/mobilemap/query/rasterquery.php	2013-05-22 14:44:11 UTC (rev 8625)
@@ -6,7 +6,7 @@
 $coord = split(',',$_GET["coord"]);
 
 //Mapfile laden
-$map= ms_newMapObj($mapfilepath.'\map.map');
+$map= ms_newMapObj($mapfilepath.'/dhm.map');
 
 //Punkt erzeugen
 $qPoint = ms_newPointObj();

Added: trunk/mapbender/http/extensions/mobilemap/query/rasterqueryWms.php
===================================================================
--- trunk/mapbender/http/extensions/mobilemap/query/rasterqueryWms.php	                        (rev 0)
+++ trunk/mapbender/http/extensions/mobilemap/query/rasterqueryWms.php	2013-05-22 14:44:11 UTC (rev 8625)
@@ -0,0 +1,158 @@
+<?php
+
+//Basic configuration of mapserver client
+
+require_once(dirname(__FILE__)."/../../../../conf/mobilemap.conf");
+require_once(dirname(__FILE__)."/../../../classes/class_connector.php");
+
+$featureInfoRequestPart =  '&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&SERVICE=WMS&LAYERS='.$rquerylayer;
+$featureInfoRequestPart .= '&QUERY_LAYERS='.$rquerylayer.'&WIDTH=101&HEIGHT=101&SRS=EPSG:'.$ggepsg;
+
+//calculate BBOX from position
+$coord = explode(',',$_GET["coord"]);
+$bbox = (string)((double)$coord[0] - 50.0) .",".(string)((double)$coord[1] - 50.0) .",".(string)((double)$coord[0] + 50.0) .",".(string)((double)$coord[1] + 50.0); 
+
+
+$featureInfoRequestPart .= '&BBOX='.$bbox.'&STYLES=&FORMAT=image/png';
+$featureInfoRequestPart .= '&INFO_FORMAT=application/vnd.ogc.gml&EXCEPTIONS=application/vnd.ogc.se_inimage&X=51&Y=51&FEATURE_COUNT=1&';
+$url = $dhmWmsFeatureInfoUrl.$featureInfoRequestPart;
+
+//Request ausführen
+// Open the Curl session
+$featureInfoConnector = new connector($url);
+//header("Content-Type: text/plain");
+//header("Content-Type: application/json");
+
+//Datenausgabe
+$gml = $featureInfoConnector->file;
+
+//Ergebnis parsen
+try {
+	//$xml = str_replace('xlink:href', 'xlinkhref', $xml);
+	//http://forums.devshed.com/php-development-5/simplexml-namespace-attributes-problem-452278.html
+	//http://www.leftontheweb.com/message/A_small_SimpleXML_gotcha_with_namespaces
+	$gmlObject = new SimpleXMLElement($gml);
+
+	if ($gmlObject === false) {
+		foreach(libxml_get_errors() as $error) {
+        		$e = new mb_exception($error->message);
+    		}
+		throw new Exception('Cannot parse GML from featureInfo in mobile Client!');
+	}
+}
+catch (Exception $e) {
+    	$e = new mb_exception($e->getMessage());
+}	
+
+if ($gmlObject !== false) {
+	//read all relevant information an put them into the mapbender wfs object
+	//xmlns="http://www.opengis.net/wfs"
+	//Setup default namespace
+
+	$gmlObject->registerXPathNamespace("gml", "http://www.opengis.net/gml");
+	$gmlObject->registerXPathNamespace("xlink", "http://www.w3.org/1999/xlink");
+	$gmlObject->registerXPathNamespace("xsi", "http://www.w3.org/2001/XMLSchema-instance");
+	//$gmlObject->registerXPathNamespace("default", "http://www.opengis.net/wfs");
+	//some debug
+	//$e = new mb_notice("XML string from memory: ".$wfs11Cap->asXML());
+	$x = $gmlObject->xpath('/msGMLOutput/mydhm_layer/mydhm_feature/value_0');
+	$hoehe = $x[0];
+	echo "Höhe: ~".$hoehe." [m]";
+} else {
+	echo "Kein Höhe gefunden!";
+}
+//HTML generieren
+
+//Rückgabe
+
+/*
+//Mapfile laden
+$map= ms_newMapObj($mapfilepath.'/dhm.map');
+
+//Punkt erzeugen
+$qPoint = ms_newPointObj();
+$qPoint->setXY($coord[0]*1,$coord[1]*1);
+
+//Layer festlegen
+$layer = $map->getLayerByName($rquerylayer);
+
+//Punktabfrage (Single)
+@$datQuery = $layer->queryByPoint($qPoint, MS_SINGLE, 1);
+ // UMRECHNUNG  Eingabe koordinatensystem -> WGS84
+$projInObj = ms_newprojectionobj("init=epsg:$ggepsg");
+$projOutObj = ms_newprojectionobj("init=epsg:4326");
+$qPoint->project($projInObj, $projOutObj);
+$WGS_X = round($qPoint->x,6);
+$WGS_Y = round($qPoint->y,6);
+print '<div id="dhmqueryId" >';
+print ('<table border="0" cellspacing="0" cellpadding="1" class="normal">');
+
+//Wenn Query erfolgreich
+     if ($datQuery == MS_SUCCESS) {
+         for ($j=0; $j<$layer->getNumResults(); $j++) {
+            $result = $layer->getResult($j);			
+			//Versionsüberprüfung	
+			if (ms_GetVersionInt() < 50600){
+				$layer->open(); 
+			}
+			
+			//Versionsüberprüfung	
+			if (ms_GetVersionInt() < 50600){
+			$shpobj = $layer->getShape($result->tileindex,$result->shapeindex);
+			}
+			else{
+			$shpobj = $layer->resultsGetShape($result->shapeindex,$result->tileindex);
+			}
+			
+			$attr = $shpobj->values;
+
+			//echo round($attr["value_0"],2);
+			$hoehe = round($attr["value_0"],1);
+			if ($hoehe <0){
+			  print '<tr ><td colspan="3" ><strong>'.$maplang['rasterquery_nodata'].'</strong></td></tr>';
+			}
+			else{
+			print '<tr><td>'.$maplang['rasterquery_h'].'</td><td><span class="hilite">'.$hoehe.'</span></td><td>m NN</td></tr>';
+			}
+			$shpobj->free(); 
+			
+			//Versionsüberprüfung		
+			if (ms_GetVersionInt() < 50600){
+				$layer->close();
+			}
+         }		
+     }
+	 else{
+	    print '<tr ><td colspan="3" ><strong>'.$maplang['rasterquery_noh'].'</strong></td></tr>';
+		//echo "Kein Wert verfügbar!";
+	} 
+
+print ('<tr bgcolor="#E6E6E6"><td colspan="3" >'.$maplang['rasterquery_gps'].'</td></tr>
+  <tr>
+    <td>Lat:</td>
+    <td colspan="2">'.$WGS_Y.'</td>
+  </tr>
+  <tr>
+    <td>Lon:</td>
+    <td colspan="2">'.$WGS_X.'</td>
+  </tr>
+  <tr bgcolor="#E6E6E6">
+    <td colspan="3" >'.$maplang['rasterquery_xy'].'</td>
+  </tr>
+  <tr>
+    <td>X</td>
+    <td colspan="2">'.round($coord[0],0).'</td>
+  </tr>
+  <tr>
+    <td>Y</td>
+    <td colspan="2">'.round($coord[1],0).'</td>
+  </tr>
+   <tr>
+    <td colspan="3" align="left"><a href="javascript:void(0);"  onClick="javascript:zoompoint('.round($coord[0],0).','.round($coord[1],0).');" ><img src="'.$applicationurl.'/img/ico_zoomin.png"  border="0" > '.$maplang['geocode_result4'].'</a></td>
+  </tr>
+  <tr>
+    <td colspan="3" align="right">');
+
+print('	</td></tr></table></div>');
+*/
+?>



More information about the Mapbender_commits mailing list