[mapserver-users] Zoom to extents - NOT
Palmer, Steve
Steve_Palmer at lpsg.com
Mon Oct 21 08:42:41 PDT 2002
A guess - your zoom variable is set to 2 or your zoomdir is set to 1 with a
zoomsize of 2
As part of your zoomall function you need to "handle" this (e.g., set zoom =
0 or zoomdir = 0)
-----Original Message-----
From: Murray, Ross [mailto:rmurray at NRCan.gc.ca]
Sent: Monday, October 21, 2002 8:05 AM
To: 'mapserver-users at lists.gis.umn.edu'
Subject: [mapserver-users] Zoom to extents - NOT
I am very new to MapServer and would appreciate any words of encouragement
you may provide before I am prematurely old.
I have a button on my HTML form called "zoomtoextents". There are seperate
buttons allowing the user to zoom in or zoom out to explore the image. The
theory was that at some point they may wish to see the entire map again, so
they should be able to do so by a single click of a button. The code I wrote
was:
function zoomall() {
document.forms[0].imgext.value = "[allext]" ;
document.forms[0].submit();
}
where "[allext]" is a constant that holds the bounding latitude/longitude
values of the map area (the value comes from a database and is set before
the mapserv.exe is called).
Problem:
No matter how much (or little) the image is zoomed, clicking
"zoomtoextents" returns an image at exactly half the maximum scale. For
example, when one of my sample maps loads for the first time, its extents
([allext]) are the bounding lat/long as described above and the scale is 1
to 500000. If I zoom in by any amount then click "zoomtoextents" I get a map
at 1 to 250000.
Go Figure?
<<Murray, Ross.vcf>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20021021/09b77c18/attachment.htm>
More information about the MapServer-users
mailing list