[mapserver-commits] r13104 - trunk/docs/en/cgi
svn at osgeo.org
svn at osgeo.org
Wed Feb 8 18:19:30 EST 2012
Author: dmiddlecamp
Date: 2012-02-08 15:19:30 -0800 (Wed, 08 Feb 2012)
New Revision: 13104
Added:
trunk/docs/en/cgi/openlayers.txt
Modified:
trunk/docs/en/cgi/index.txt
Log:
initial checkin of documentation for openlayers viewer feature, for #3549
Modified: trunk/docs/en/cgi/index.txt
===================================================================
--- trunk/docs/en/cgi/index.txt 2012-02-08 23:19:13 UTC (rev 13103)
+++ trunk/docs/en/cgi/index.txt 2012-02-08 23:19:30 UTC (rev 13104)
@@ -20,5 +20,6 @@
controls
runsub
wrapper
+ openlayers
Added: trunk/docs/en/cgi/openlayers.txt
===================================================================
--- trunk/docs/en/cgi/openlayers.txt (rev 0)
+++ trunk/docs/en/cgi/openlayers.txt 2012-02-08 23:19:30 UTC (rev 13104)
@@ -0,0 +1,83 @@
+.. index::
+ simple: OpenLayers viewer
+
+.. _openlayers:
+
+*****************************************************************************
+ MapServer OpenLayers Viewer
+*****************************************************************************
+
+MapServer provides a simple, built-in method for testing a mapfile using OpenLayers.
+This feature is for testing/development purposes only, and not for production or deploying
+full-featured sites. You can preview, test, and navigate a mapfile by accessing a special
+url which will return a built-in OpenLayers template.
+
+.. note: This feature was discussed in `rfc 63 <http://mapserver.org/development/rfc/ms-rfc-63.html>`_
+ and in this ticket http://trac.osgeo.org/mapserver/ticket/3549
+
+
+Using the OpenLayers viewer
+-----------------------------------------------------------------------------
+
+
+Opening the OpenLayers viewer in your browser
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Lets assume you are running mapserver on your local machine, and you
+have the Itasca demo setup, a basic url would be::
+
+ http://localhost/cgi-bin/mapserv?mode=browse&template=openlayers&layer=lakespy2&layer=dlgstln2&map=%2Fvar%2Fwww%2Fworkshop%2Fitasca.map&
+
+Here is a quick breakdown of that url:
+
+* Basic Parameters for activating the OpenLayers browser::
+
+ ?mode=browse
+ &template=openlayers
+
+
+* Basic Map / Layer Parameters::
+
+ &map=/var/www/workshop/itasca.map
+ &layer=lakespy2
+ &layer=dlgstln2
+
+**That's it!**
+
+
+
+Opening the OpenLayers viewer in the form of a WMS request
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+This feature is useful when debugging WMS requests. You can write one of these by hand,
+or copy the URL for a WMS tile. Running the following should give you a simple OpenLayers
+demo around the BBOX::
+
+ http://localhost/cgi-bin/mapserv?map=/var/www/workshop/itasca.map&LAYERS=lakespy2&VERSION=1.1.1&SERVICE=WMS&REQUEST=GetMap&FORMAT=application/openlayers&BBOX=429956.19803725,5231780.0814818,444078.32296225,5245902.2064068&WIDTH=512&HEIGHT=512&SRS=EPSG:26915
+
+
+Here is a quick breakdown of the interesting parts of that URL:
+
+* Special Parameter for activating the OpenLayers viewer::
+
+ &FORMAT=application/openlayers
+
+* Basic MapServer Parameters::
+
+ ?map=/var/www/workshop/itasca.map
+
+* Basic WMS parameters::
+
+ #Our Bounding Box, Projection, and Layers
+ &BBOX=429956.19803725,5231780.0814818,444078.32296225,5245902.2064068
+ &SRS=EPSG:26915
+ &LAYERS=lakespy2
+
+ #Version and other WMS request params
+ &VERSION=1.1.1
+ &TRANSPARENT=true
+ &SERVICE=WMS
+ &REQUEST=GetMap
+ &WIDTH=512
+ &HEIGHT=512
+
More information about the mapserver-commits
mailing list