[MAPSERVER-USERS] problem with map.zoomToExtent

Alan Boudreault aboudreault at mapgears.com
Mon Aug 11 09:29:32 EDT 2008


Reena,

I don't understand why your "map.zoomToExtend()" call don't work. This 
is a very basic function.  Are you sure that the parameters used for 
create the OpenLayers.Bounds object are good ? (str1 = left, str2 = 
bottom, str3 = right, str4 = top). If so, can you show us some code ... 
in this way, we'll be more able to check what could be the problem.

Regards,
Alan

S.Reena wrote:
> i have three files... one html, one javascript and one php....i am handling
> database through php file and sending the result of that to a function in
> javascript file..
> echo " \"javascript:zoomVillage($box1,$box2,$box3,$box4)\" Open Map ";
>
> These are ST_box2D() data which i hv split in 4 parts ...the thing is if i
> alert these values in that function..its working..but i i do like
>
> map.zoomToExtent(new OpenLayers.Bounds(str1,str2,str3,str4))  where str1 etc
> contain the passed values.. 
>
> this doesn't work..
>
> Can any1 help?
>
> Cheers,
> S.Reena
>   


-- 
Alan Boudreault
Mapgears
http://www.mapgears.com



More information about the mapserver-users mailing list