[Users] WMSGetFeatureInfo and GeoExt Popup

Michael Tafel MTafel at drcog.org
Fri Apr 30 18:34:50 CEST 2010


Hello,

I recently upgraded to GeoServer 2.0.1 and the GeoExt Popup I was populating with a getfeatureinfo html response will no longer poplulate with infoFormat:'text/html'. It will populate when the infoFormat is 'text/plain' but I want to manipulate the output to the request with html.

Now the window remains empty.

This worked fine before the upgrade and am I am having issuses going back to 2.0.0 geoserver.

Code:

var info;
             //Getfeatureinfo object
             info = new OpenLayers.Control.WMSGetFeatureInfo({
                                     url: '/geoserver/wms',
            title: 'Identify features by clicking',
               layers: [counts],
               queryVisible: true,
               infoFormat: 'text/html',
               maxFeatures: 25,
               hover:false
                });

            info.events.on({
           getfeatureinfo: function(e) {
                   new GeoExt.Popup({         //utilizing the GeoExt popup functionality
                   title: "traffic counts",
                    width: 400,
                    height: 215,
                    autoScroll: true,
                    map: map,
                    lonlat: map.getLonLatFromPixel(e.xy),
                    html: e.html
                }).show();
           }
        });
        map.addControl(info);
        info.activate();

Thanks in advance,

Cheers,

--Mike



Michael Tafel| GIS Specialist| Denver Regional Council of Governments

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.geoext.org/pipermail/users/attachments/20100430/26b67e94/attachment.htm 


More information about the Users mailing list