Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I need to put checkbox with name "Zoom to extents" which will zoom to full map extent (first extent which appears by opening web page). Can someone help me? In mapfile I have this "EXTENT 563090 5072655 588220 5093325".

share|improve this question

1 Answer 1

up vote 3 down vote accepted

Maybe this tutorial can help: http://docs.huihoo.com/mapserver/5.2.1/mapscript/php/by_example.html

This code will zoom out, zoom in, pan, and restore to full extent the image displayed in the previous example.

share|improve this answer
That tutorial is for using PHP mapscript (note: current version is at mapserver.org/mapscript/php/by_example.html, search the page for 'Full Extent'). If you want "old school" CGI mapserver, try this tutorial: biometry.gis.umn.edu/tutorial/sections.html and/or the CGI variables page mapserver.org/cgi/controls.html. –  neuhausr Jun 13 '11 at 14:25

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.