Finally I found the problem (I think)...<br>I was using mssql2008 database...<br>Changed to Postgis, and all works fine...<br><br>Probably a bug ...<br><br>Stella<br><br><div class="gmail_quote">2010/1/27 stela anders <span dir="ltr"><<a href="mailto:stelaanders@gmail.com">stelaanders@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Replied from my husband acc...<br>My bad<br><br>sorry<br><br>Stella<br><br><div class="gmail_quote">
2010/1/27 Paul james <span dir="ltr"><<a href="mailto:pauljame@gmail.com" target="_blank">pauljame@gmail.com</a>></span><div><div></div><div class="h5"><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>Hi !</div>
<div> </div>
<div>I dont think that it is the problem, because WMSGetFeatureInfo is generating the "correct" url (I think)...</div>
<div> </div>
<div>Anyway I tested querying only 1 single layer and got the same result...<br><br>Dammit :(</div>
<div> </div>
<div>Thanks anyway</div>
<div> </div>
<div>Stella</div><div><div></div><div>
<div> </div>
<div class="gmail_quote">On Wed, Jan 27, 2010 at 12:24 PM, Eichner, Andreas - SID-NLKM <span dir="ltr"><<a href="mailto:Andreas.Eichner@sid.sachsen.de" target="_blank">Andreas.Eichner@sid.sachsen.de</a>></span> wrote:<br>
<blockquote style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;" class="gmail_quote"><br>Hi Stella,<br><br>according to <a href="http://dev.openlayers.org/docs/files/OpenLayers/Control/WMSGetFeatureInfo-js.html" target="_blank">http://dev.openlayers.org/docs/files/OpenLayers/Control/WMSGetFeatureInfo-js.html</a> the WMSGetFeatureInfo control's constructor takes an array of OpenLayers.Layer.WMS objects. But you give it the list you used to draw as one layer. So you should create two OpenLayers.Layer.WMS objects, one for layer "Test1" and one for "Test2" and then give the control an array of them.<br>
So if I'm correct it should look something like that:<br><br>var _test1 = new OpenLayers.Layer.WMS(<br> "MyLayer 1",<br> _mapfilex,<br> {<br> layers: [ 'Test1'],<br>
<div> format: "image/png",<br> transparent: "true"<br> },<br> {<br> isBaseLayer: false,<br> buffer: 0,<br>
visibility: true<br> }<br> );<br></div>var _test2 = new OpenLayers.Layer.WMS(<br> "MyLayer 2",<br> _mapfilex,<br> {<br>
layers: [ 'Test2'],<br>
<div> format: "image/png",<br> transparent: "true"<br> },<br> {<br> isBaseLayer: false,<br> buffer: 0,<br>
visibility: true<br> }<br> );<br></div>
<div>var infoCtl = new OpenLayers.Control.WMSGetFeatureInfo({<br></div> layers: Array(_test1, _test2),<br>
<div> title: 'Click on the map to get information on layers',<br> queryVisible: true,<br> infoFormat: 'text/html'<br> });<br>
infoCtl.events.register("getfeatureinfo",map,showInfo);<br><br>function showInfo(evt) {<br> alert(evt.text);<br>}<br><br></div>Also I don't know how MapServer handles queries to two or more layers if at least one of them declares header or footer - it might happen that a layer without a header is processed before one with. And from what you got back I suggest that MapServer processes each layer if it was queried alone and therefore outputs the HTTP "Content-type" header after processing the first layer.<br>
<br><br>Mit freundlichen Grüßen,<br><font color="#888888"><br>Andreas Eichner<br></font>
<div>
<div></div>
<div>_______________________________________________<br>mapserver-users mailing list<br><a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br><a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
</div></div></blockquote></div><br>
</div></div><br>_______________________________________________<br>
mapserver-users mailing list<br>
<a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
<br></blockquote></div></div></div><br>
</blockquote></div><br>