Advertisement
Guest User

Untitled

a guest
Oct 23rd, 2014
124
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.30 KB | None | 0 0
  1. var options = {
  2. controls: [],
  3. maxExtent: bounds,
  4. maxResolution: 0.02741796875,
  5. projection: "EPSG:3857",
  6. units: 'm'
  7. };
  8.  
  9. map = new OpenLayers.Map('map-id', options);
  10.  
  11. var ccounties = new OpenLayers.Layer.WMS(
  12. "Map - Enschede", "http://localhost:8083/geoserver/thesis/wms",
  13. {
  14. srs: 'EPSG:3857',
  15. layers: 'thesis:Ensche',
  16. styles: '',
  17. format:'image/png'
  18. },
  19. {singleTile: true, ratio: 1}
  20. );
  21.  
  22. map.addLayer(ccounties);
  23.  
  24. // build up all controls
  25. map.addControl(new OpenLayers.Control.PanZoomBar({
  26. position: new OpenLayers.Pixel(2, 15)
  27. }));
  28. map.addControl(new OpenLayers.Control.Navigation());
  29. map.addControl(new OpenLayers.Control.Scale());
  30. map.addControl(new OpenLayers.Control.MousePosition());
  31. map.zoomToExtent(bounds);
  32.  
  33. </script>
  34. </body>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement