<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
Hello Kai,<br>
<br>
you should set the property "location" instead of "lonlat" in your
popup:<br>
<br>
<i> featureInfo.events.on({<br>
getfeatureinfo: function(e) {<br>
new GeoExt.Popup({<br>
title: "Feature Info",<br>
width: 200,<br>
height: 150,<br>
autoScroll: true,<br>
maximizable: true,<br>
map: mappanel.map,<br>
<b>location:
mappanel.map.getLonLatFromPixel(e.xy),</b><br>
html: e.text<br>
}).show();<br>
}<br>
})</i>;<br>
<br>
Best regards,<br>
Chris<br>
<br>
<br>
<br>
Am 13.01.2011 15:59, schrieb Kai Volland:
<blockquote
cite="mid:40948784.1195436.1294930794922.JavaMail.fmail@mwmweb055"
type="cite">
<div style="min-height: 200px; background-image:
url("https://img.web.de/v/p.gif"); background-repeat:
repeat; background-color: rgb(255, 255, 255); font-family:
verdana,geneva; font-size: 9pt; padding-left: 0px;"><span
style="font-size: 9pt;"><span style="font-family:
verdana,geneva;"><span style="background-color:
transparent;"><span style="color: rgb(0, 0, 0);"><span
style="color: rgb(0, 0, 0);">Hello everybody,<br>
<br>
i tried to fetch some featureinfos from geoserver and
display in a popup.<br>
I used this code:<br>
<br>
</span></span></span></span></span><i><span
style="color: rgb(0, 128, 0);"> // GetFeatureInfo</span><br>
<br>
var featureInfo = new
OpenLayers.Control.WMSGetFeatureInfo({<br>
url: '<a class="moz-txt-link-freetext" href="http://sfb806srv.uni-koeln.de:8080/geoserver/wms">http://sfb806srv.uni-koeln.de:8080/geoserver/wms</a>',<br>
layers:[pfeile],<br>
info_format:'text/plain',<br>
});<br>
<br>
featureInfo.events.on({<br>
getfeatureinfo: function(e) {<br>
new GeoExt.Popup({<br>
title: "Feature Info",<br>
width: 200,<br>
height: 150,<br>
autoScroll: true,<br>
maximizable: true,<br>
map: mappanel.map,<br>
lonlat: mappanel.map.getLonLatFromPixel(e.xy),<br>
html: e.text<br>
}).show();<br>
}<br>
});<br>
mappanel.map.addControl(featureInfo);<br>
featureInfo.activate();</i><br>
<br>
A click on the map results in an empty popup and the following
errors in <b>Firebug</b>:<br>
<br>
<div role="listitem" class="subLogRow focusRow errorTitle"><span
style="color: rgb(255, 0, 0);"><span class="errorMessage">centerPx
is null</span></span></div>
<div role="listitem" class="subLogRow focusRow errorSource-show
errorSourceBox"><span style="color: rgb(0, 128, 0);"><img
moz-do-not-send="true"
src="chrome://firebug/content/blank.gif" role="checkbox"
title="Bei diesem Fehler anhalten" class="a11yFocus
errorBreak"><a moz-do-not-send="true"
title="this.setPosition(centerPx.x + mapBox.x - dx,
centerPx.y + mapBox.y - dy);" class="a11yFocus
errorSource"> this.setPosition(centerPx.....x - dx,
centerPx.y + mapBox.y - dy); <span style="color: rgb(0,
0, 0);">Popup.js (Line 244)<br>
<br>
The GET-Request is also shown in red.<br>
Params and Header are ok i think. But Response and Html
keep empty.<br>
<br>
I hope anyone can help me.<br>
<br>
Kind regards Kai<br>
</span></a></span></div>
<br>
<br>
<br>
<br>
<br>
</div>
<br>
<br>
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td bgcolor="#000000"><img moz-do-not-send="true"
src="https://img.web.de/p.gif" alt="" height="1"
width="1" border="0"></td>
</tr>
<tr>
<td style="font-family: verdana; font-size: 12px;
line-height: 17px;">WEB.DE DSL Doppel-Flat ab 19,99
€/mtl.! Jetzt mit <br>
gratis Handy-Flat! <a moz-do-not-send="true"
href="http://produkte.web.de/go/DSL_Doppel_Flatrate/2"><b>http://produkte.web.de/go/DSL_Doppel_Flatrate/2</b></a></td>
</tr>
</tbody>
</table>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@geoext.org">Users@geoext.org</a>
<a class="moz-txt-link-freetext" href="http://www.geoext.org/cgi-bin/mailman/listinfo/users">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
</body>
</html>