[mapserver-commits] r8322 - in trunk/docs: . _static

svn at osgeo.org svn at osgeo.org
Mon Dec 29 16:20:06 EST 2008


Author: tbonfort
Date: 2008-12-29 16:20:05 -0500 (Mon, 29 Dec 2008)
New Revision: 8322

Added:
   trunk/docs/_static/ol.js
Modified:
   trunk/docs/index.txt
Log:
add slippy map to index page


Added: trunk/docs/_static/ol.js
===================================================================
--- trunk/docs/_static/ol.js	                        (rev 0)
+++ trunk/docs/_static/ol.js	2008-12-29 21:20:05 UTC (rev 8322)
@@ -0,0 +1,30 @@
+var lon = 261330;
+var lat = 6250266;
+var zoom = 7;
+var map;
+
+function olmapinit(){
+  map = new OpenLayers.Map( 'olmap', {
+restrictedExtent: new OpenLayers.Bounds(243000,6236000,278000,6263000)
+      });
+  
+        var wms = new OpenLayers.Layer.TileCache( "S3", 
+        ['http://mapserverosm.s3.amazonaws.com',
+        'http://s3.amazonaws.com/mapserverosm'],
+        'parisosm',
+        {
+          maxExtent: new OpenLayers.Bounds(-571405,5067685,1061388,6637184),
+          resolutions:[1763.8879363894034,881.9439681947017,352.7775872778807,176.38879363894034,88.19439681947017,35.27775872778806,17.63887936389403,8.819439681947015,3.527775872778806,1.763887936389403],
+          units: 'm',
+          projection:new OpenLayers.Projection("EPSG:900913"),
+          buffer:0,
+          isBaselayer:true
+        } );
+
+map.addLayers([wms]);
+OpenLayers.IMAGE_RELOAD_ATTEMPTS = 3;
+if(!map.getCenter())
+  map.setCenter(new OpenLayers.LonLat(lon, lat), zoom);
+}
+OpenLayers.Event.observe(window, "load", olmapinit);
+

Modified: trunk/docs/index.txt
===================================================================
--- trunk/docs/index.txt	2008-12-29 21:08:20 UTC (rev 8321)
+++ trunk/docs/index.txt	2008-12-29 21:20:05 UTC (rev 8322)
@@ -1,13 +1,14 @@
 .. _home:
 
+.. raw:: html
+
+    <table style="height:300px;"><tr><td style="width:50%; vertical-align:top">
+
+
 *****************************************************************************
  Welcome to MapServer
 *****************************************************************************
 
-.. warning::
-    This website is a preview of the upcoming version of the MapServer
-    website.  It is not expected to go "live" until Dec 30th, 2008.
-
 MapServer is an `Open Source`_ geographic data rendering engine, released
 under an :ref:`MIT-style license <license>`. MapServer is *not* a
 full-featured `GIS`_ system, nor does it aspire to be, and it runs on
@@ -16,7 +17,17 @@
 administers the project which is maintained, improved, and supported by
 developers from around the world.
 
+.. raw:: html
 
+    </td><td width="50%" style="width:50%;height:100%"> <div id="olmap" style="width:100%;height:100%;margin:0px;"></div></td></tr><tr style="margin-top:0px;padding-top:0px"><td colspan="2" style="text-align:right"><span style="width:100%;text-align:right;font-size:x-small;">map data by <a href="http://openstreetmap.org">openstreetmap</a></td></tr></table>
+    <script src="http://www.openlayers.org/api/OpenLayers.js"></script>
+    <script src="_static/ol.js"></script>
+
+.. warning::
+    This website is a preview of the upcoming version of the MapServer
+    website.  It is not expected to go "live" until Dec 30th, 2008.
+
+
 Announcements
 -------------------------------------------------------------------------------
 



More information about the mapserver-commits mailing list