Hello, I have a map. Base layer is standard google maps, SRS of map is EPSG:900913. I have a PostGIS database with Tiger state boundaries, native SRS is EPSG:4269.
I would like to overlay the tiger data on top of google maps. Here is the entire HTML/Javascript snippet: <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>WMS Reprojection Example</title> <script src="http://openlayers.org/api/OpenLayers.js" type="text/javascript"></script> <script src=" http://maps.google.com/maps?file=api&v=2&sensor=true_or_false&key=ABQIAAAAo2c5r7VgSxo43IHrZeBAoBTWcxCzB35ZqF_ujzxzX_fuKZ1t-BRfAjPqLC0WSahNI2hYIsaJL6PKVA" type="text/javascript"></script> <script defer="defer" type="text/javascript"> function init() { var mercator = new OpenLayers.Projection("EPSG:900913"); var geographic = new OpenLayers.Projection("EPSG:4269"); var maxExt = new OpenLayers.Bounds( -20037508, -20037508, 20037508, 20037508 ); map = new OpenLayers.Map( 'map', { projection: mercator, displayProjection: geographic, units: 'm', maxResolution: 156543.0039, maxExtent: maxExt } ); var googleLayer = new OpenLayers.Layer.Google( "Google Layer", {spericalMercator: true} ); var wms = new OpenLayers.Layer.WMS( "State Boundaries WMS", "http://localhost:8080/geoserver/wms", { layers: "state_boundaries", srs: 'EPSG:4269', format:'image/png8', transparent:'true', tiled: 'true' }, {'isBaseLayer': false}/*, { projection: "EPSG:4269" }*/ ); map.addLayer( googleLayer ); map.addLayer( wms ); var ddBounds = new OpenLayers.Bounds( -73.839111, 40.287907, -68.214111, 44.441624 ); map.zoomToExtent( ddBounds.transform(geographic, mercator) ); } </script> </head> <body onload="init()"> <div style="width:100%; height:100%; background-color: #99B3CC" id="map"></div> </body> </html> An interesting point is. All the WMS requests that are made to my local geoserver instance do in fact return blank tiles. When I look at all the WMS requests there are google WMS requests and WMS requests to my local host for the "wms" layer. The local WMS requests look like this: http://localhost:8080/geoserver/wms?LAYERS=state_boundaries&STYLES=stateBoundaries&SRS=EPSG%3A900913&FORMAT=image%2Fpng8&TRANSPARENT=true&TILED=true&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&BBOX=-88,32.9375,-85.1875,35.75&WIDTH=256&HEIGHT=256 Notice the SRS=EPSG%3A900913 When I change this URL to have SRS=EPSG%3A4269 I get snippets of state boundaries but they look stretched vertically. Any thoughts/ideas? thank you -- Signed, Alessandro Ferrucci
_______________________________________________ Users mailing list Users@openlayers.org http://openlayers.org/mailman/listinfo/users