markers = null; } // Now initialise the map var options = { units: "m" , numZoomLevels: 16 , controls:[], projection: proj_900913, 'displayProjection': proj_4326 }; map = new OpenLayers.Map('ReporterMap', options); <?php echo map::layers_js(FALSE); ?> map.addLayers(<?php echo map::layers_array(FALSE); ?> ); map.addControl(new OpenLayers.Control.Navigation()); map.addControl(new OpenLayers.Control.PanZoom()); map.addControl(new OpenLayers.Control.MousePosition()); map.addControl(new OpenLayers.Control.LayerSwitcher()); // Create the markers layer markers = new OpenLayers.Layer.Markers("Markers"); map.addLayer(markers);
, units: "m" , projection: MapProj , 'displayProjection': DispProj , maxExtent: new OpenLayers.Bounds(-20037508.34, -20037508.34, 20037508.34, 20037508.34) , controls: [ new OpenLayers.Control.Navigation(), new OpenLayers.Control.MouseDefaults(), new OpenLayers.Control.PanZoom(), new OpenLayers.Control.ArgParser(), new OpenLayers.Control.MousePosition(), new OpenLayers.Control.LoadingPanel({minSize: new OpenLayers.Size(573, 366)}) ] }; var map = new OpenLayers.Map('map', options); <?php echo map::layers_js(TRUE); ?> map.addLayers(<?php echo map::layers_array(TRUE); ?> ); // Transform feature point coordinate to Spherical Mercator preFeatureInsert = function(feature) { var point = new OpenLayers.Geometry.Point(feature.geometry.x, feature.geometry.y); OpenLayers.Projection.transform(point, DispProj, MapProj); }; // Create the markers layer
*/ var options = { units: "mi", numZoomLevels: 20, controls:[], projection: proj_900913, 'displayProjection': proj_4326, eventListeners: { "zoomend": mapMove }, 'theme': null }; map = new OpenLayers.Map('map', options); map.addControl( new OpenLayers.Control.LoadingPanel({minSize: new OpenLayers.Size(573, 366)}) ); <?php echo map::layers_js(TRUE); ?> map.addLayers(<?php echo map::layers_array(TRUE); ?>); // Add Controls map.addControl(new OpenLayers.Control.Navigation()); map.addControl(new OpenLayers.Control.Attribution()); map.addControl(new OpenLayers.Control.PanZoomBar()); map.addControl(new OpenLayers.Control.MousePosition( { div: document.getElementById('mapMousePosition'), numdigits: 5 })); map.addControl(new OpenLayers.Control.Scale('mapScale')); map.addControl(new OpenLayers.Control.ScaleLine()); map.addControl(new OpenLayers.Control.LayerSwitcher());
*/ var options = { units: "mi", numZoomLevels: 18, controls:[], projection: proj_900913, 'displayProjection': proj_4326, eventListeners: { "zoomend": mapMove }, 'theme': null }; map = new OpenLayers.Map('map', options); map.addControl( new OpenLayers.Control.LoadingPanel({minSize: new OpenLayers.Size(573, 366)}) ); <?php echo map::layers_js(FALSE); ?> map.addLayers(<?php echo map::layers_array(FALSE); ?>); // Add Controls map.addControl(new OpenLayers.Control.Navigation()); map.addControl(new OpenLayers.Control.Attribution()); map.addControl(new OpenLayers.Control.PanZoomBar()); map.addControl(new OpenLayers.Control.MousePosition( { div: document.getElementById('mapMousePosition'), numdigits: 5 })); map.addControl(new OpenLayers.Control.Scale('mapScale')); map.addControl(new OpenLayers.Control.ScaleLine()); map.addControl(new OpenLayers.Control.LayerSwitcher());