city-locatting OK... next step! =)

Stephen Lime steve.lime at dnr.state.mn.us
Tue Nov 14 11:32:47 EST 2000


To have a browsable map you MUST set imgext to be the extent of the
displayed map. The way you've got it set up now doesn't give you that
information. MapServer certainly calculates it in building the image but 
since your just retrieving the image there's no way to get it back to
you since you're not using templates. 

The solution is to calculate the extent in the client using a bit of javascript.
This is not hard. Then extent in hand you can use the image in a normal
mapserver form interface. Here's an example that does just that.

http://www.dnr.state.mn.us/cgi-bin/mapserv3.3?imgxy=149.5+149.5&map=compass%2Fcompass.map&imgext=496873.437871+4989627.233203+503946.561551+4996691.064587&application=Recreation+Compass&layers=&zoom=2&mode=query&img.x=164&img.y=125

Steve

Stephen Lime
Internet Applications Analyst

Minnesota DNR
500 Lafayette Road
St. Paul, MN 55155
651-297-2937

>>> Nicolau Werneck <nwerneck at yahoo.com.br> 11/10/00 10:48AM >>>
   Hi...
   OK, I've successfully used the [shpmidx|y] 
thing... But now, how can I use that to continue to
browse trough the map?
   Why won't something like
"???/mapserv?map=<?>&mapxy=-43+-20&scale=4&img.x=200&img.y=400"
work? Isn't defining a mapxy/scale pair the same as
defining a mapext? they should be equivalent!

(I'm almost understanding this thing. I hope I can
contribute to the documentation, because this program
rocks! :)   )

-- Nicolau

________________________________________________________________________
Do You Yahoo!?
Crie o seu e-mail grátis do Yahoo! Mail com 6 Megabytes livres!
http://mail.yahoo.com.br




More information about the mapserver-users mailing list