Concise config. No init.
This commit is contained in:
@@ -24,7 +24,7 @@
|
|||||||
|
|
||||||
<script src="../lib/OpenLayers.js"></script>
|
<script src="../lib/OpenLayers.js"></script>
|
||||||
</head>
|
</head>
|
||||||
<body onload="init()">
|
<body>
|
||||||
<h1 id="title">OpenLayers Spherical Mercator Example</h1>
|
<h1 id="title">OpenLayers Spherical Mercator Example</h1>
|
||||||
|
|
||||||
<div id="tags">
|
<div id="tags">
|
||||||
@@ -39,17 +39,14 @@
|
|||||||
<div id="docs"></div>
|
<div id="docs"></div>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
||||||
var maxExtent = new OpenLayers.Bounds(-20037508, -20037508, 20037508, 20037508),
|
var map = new OpenLayers.Map({
|
||||||
restrictedExtent = maxExtent.clone(),
|
div: "map",
|
||||||
maxResolution = 156543.0339;
|
|
||||||
|
|
||||||
map = new OpenLayers.Map('map', {
|
|
||||||
projection: new OpenLayers.Projection("EPSG:900913"),
|
projection: new OpenLayers.Projection("EPSG:900913"),
|
||||||
displayProjection: new OpenLayers.Projection("EPSG:4326"),
|
displayProjection: new OpenLayers.Projection("EPSG:4326"),
|
||||||
units: "m",
|
units: "m",
|
||||||
numZoomLevels: 18,
|
numZoomLevels: 18,
|
||||||
maxResolution: maxResolution,
|
maxResolution: 156543.0339,
|
||||||
maxExtent: maxExtent
|
maxExtent: new OpenLayers.Bounds(-20037508, -20037508, 20037508, 20037508),
|
||||||
});
|
});
|
||||||
|
|
||||||
// create Google Mercator layers
|
// create Google Mercator layers
|
||||||
|
|||||||
Reference in New Issue
Block a user