problem in zooming.

orkun temiz at DEPREM.GOV.TR
Mon Jun 13 02:58:19 EDT 2005


hello

I am trying to zoom a map to a specified extent.
I have used these code fragment:
~~~~~
     $minx=467035.624;      //  they are the  coordinates  I want to  
show the map
       $miny=4559092.479;
       $maxx=472109.624;
       $maxy=4564954.479;
     
      $extent_to_set = explode(" ",$HTTP_POST_VARS["extent"]);
      $map->setextent($extent_to_set[0],$extent_to_set[1],
               $extent_to_set[2],$extent_to_set[3]);

      $my_extent = ms_newrectObj();

      $my_extent->setextent($extent_to_set[0],$extent_to_set[1],
                                        
$extent_to_set[2],$extent_to_set[3]);

      $zoom_rect = ms_newRectObj();

      $zoom_rect->setextent($minx,$miny,$maxx,$maxy);

      $map->zoomrectangle($zoom_rect,$map->width,$map->height,$my_extent);

      $extent_to_html = $minx." ".$miny." ".$maxx." ".$maxy;

   ~~~~~~~~~~~~~

But it displays the map in unzoomed extent (full extent)

How can I show the map in the extent  I specified
(minx,miny,maxx,maxy) ?

regards

Ahmet Temiz

______________________________________
XamimeLT - installed on mailserver for domain @deprem.gov.tr
Queries to: postmaster at deprem.gov.tr
______________________________________
The views and opinions expressed in this e-mail message are the sender's own
and do not necessarily represent the views and the opinions of Earthquake Research Dept.
of General Directorate of Disaster Affairs.

Bu e-postadaki fikir ve gorusler gonderenin sahsina ait olup, yasal olarak T.C.
B.I.B. Afet Isleri Gn.Mud. Deprem Arastirma Dairesi'ni baglayici nitelikte degildir.



More information about the mapserver-users mailing list