Don't forget to configure your map with the appropriate options for
Web Mercator layers:

{
    projection: "EPSG:3857",
    units: "m",
    maxResolution: 156543.0339,
    maxExtent: [-20037508.34, -20037508.34, 20037508.34, 20037508.34]
}

Andreas.

On Tue, Dec 6, 2011 at 11:46 PM, Puneet Kishor <[email protected]> wrote:
> I have a simple WMS (served by MapServer) overlaid on a Google Map baselayer 
> defined like so
>
>        var layer = new OpenLayers.Layer.WMS(
>                "Layer name",
>                "http://path/to/cgi-bin/app";,
>                {layers: "layer", transparent: true},
>                {isBaseLayer: false, opacity: 0.6}
>        );
>
> The above works very well but, now I have to get the above layer via a proxy. 
> As is, I end up getting the complete map repeated in every tile. So, I 
> changed the layer definition to the following
>
>        var layer = new OpenLayers.Layer.WMS(
>                "Layer name",
>                "http://path/to/proxy/app";,
>                {layers: "layer", transparent: true},
>                {isBaseLayer: false, opacity: 0.6, singleTile: true}
>        );
>
> Now I get a single complete map, however, it doesn't align with the Google 
> Map baselayer. I tried adding `sphericalMercator: true` to the layer 
> definition but no joy.
>
> Suggestions?
>
>
> --
> Puneet Kishor_______________________________________________
> Users mailing list
> [email protected]
> http://lists.osgeo.org/mailman/listinfo/openlayers-users



-- 
Andreas Hocevar
OpenGeo - http://opengeo.org/
Expert service straight from the developers.
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users

Reply via email to