Question

The bbox of OpenLayers.Control.GetFeature works in utm when the baselayer is 900913 ie. google/bing/etc) and in long/lat when the baselayer is 4326 (ie. my postgis layers served by mapserver), no matter what overlays them. This is what openlayers says.

So, how can I force bbox to be in long/lat when I use one of my layers over google for example? I do want the bbox being in long/lat rather than 900913 (ie. using baselayer projection). I've read many webs about this but with geoserver, some posts about mapserver say that both EPSG:900913 and EPSG:4326 must be set in METADATA, I changed that and also assigned "srs" and "projection" (with the appropriate expression) in my layers (and in protocols) but with no effect in bbox at all. What else could I try?

Any idea will be appreciated, thanks in advance,

Gery

Was it helpful?

Solution

To solve this problem is necessary to use prototype with OpenLayers.Control.GetFeature and then use .transform with epsg4326 and epsg900913, a bit more info about here: OpenLayers.Class with OpenLayers.Control.GetFeature

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top