[Mapserver-users] how to get extents after using zoomscale()
Daniel Morissette
morissette at dmsolutions.ca
Mon Dec 15 06:38:14 PST 2003
Stephen Clark wrote:
> // get the extent after the zoom operation
>
> $my_RectObj_after_zoom = ms_newRectObj();
> $my_RectObj_after_zoom = $map->extent;
>
> // print out the map extent now
> print " the map extent after zoom is [0] : $my_RectObj_after_zoom[0]
> <br>";
> print " the map extent after zoom is [1] : $my_RectObj_after_zoom[1] <br>";
> print " the map extent after zoom is [2] : $my_RectObj_after_zoom[2] <br>";
> print " the map extent after zoom is [3] : $my_RectObj_after_zoom[3] <br>";
>
>
The rectObj is not an array: it's an object with 4 member variables:
Try using instead:
$my_RectObj_after_zoom->minx
$my_RectObj_after_zoom->miny
$my_RectObj_after_zoom->maxx
$my_RectObj_after_zoom->maxy
Daniel
--
------------------------------------------------------------
Daniel Morissette morissette at dmsolutions.ca
DM Solutions Group http://www.dmsolutions.ca/
------------------------------------------------------------
More information about the MapServer-users
mailing list