1 <html xmlns="http://www.w3.org/1999/xhtml">
3 <title>OpenLayers Example</title>
4 <link rel="stylesheet" href="../theme/default/style.css" type="text/css" />
5 <link rel="stylesheet" href="style.css" type="text/css" />
6 <script src="../lib/OpenLayers.js"></script>
7 <script type="text/javascript">
8 // making this a global variable so that it is accessible for
9 // debugging/inspecting in Firebug
14 map = new OpenLayers.Map('map');
16 var ol_wms = new OpenLayers.Layer.WMS(
18 "http://labs.metacarta.com/wms/vmap0",
22 var jpl_wms = new OpenLayers.Layer.WMS(
24 "http://t1.hypercube.telascience.org/cgi-bin/landsat7",
28 var dm_wms = new OpenLayers.Layer.WMS(
30 "http://www2.dmsolutions.ca/cgi-bin/mswms_gmap",
32 layers: "bathymetry,land_fn,park,drain_fn,drainage," +
33 "prov_bound,fedlimit,rail,road,popplace",
34 transparent: "true", format: "image/png"},
36 minResolution: 0.17578125,
37 maxResolution: 0.703125
41 map.addLayers([ol_wms, jpl_wms, dm_wms]);
42 map.addControl(new OpenLayers.Control.LayerSwitcher());
43 map.zoomToMaxExtent();
47 <body onload="init()">
48 <h1 id="title">OpenLayers Example</h1>
51 Demonstrate a simple map with an overlay that includes layer switching controls.
53 <div id="map" class="smallmap"></div>