[Cartoweb-users] calling project and recentering on an id
Emmanuel BELO
emmanuel.belo at microgis.ch
Thu Mar 16 05:46:00 EST 2006
Hi,
i think it is possible. Take firefox 1.5 and the developers toolbar.
Convert your post form to get and do the recenter query. You can then
study the parameters in the url: With this information you can do the
recenter on id.
For the second position, there is a function in postgis that gives you
the bounding box of your object
(http://postgis.refractions.net/docs/ch06.html#id2790699):
Envelope(geometry)
Returns a POLYGON representing the bounding box of the geometry.
OGC SPEC s2.1.1.1 - The minimum bounding box for this Geometry,
returned as a Geometry. The polygon is defined by the corner points of
the bounding box ((MINX, MINY), (MAXX, MINY), (MAXX, MAXY), (MINX,
MAXY), (MINX, MINY))."
Do the same for the parameters,
regards,
eb
Valerio Noti wrote:
> Sorry for my last message: It had the same content of this one but a
> wrong object (was 'managing project')
>
> ************************************************************************
>
> Hello,
>
> I'd like to call a cartoweb project from an external page and after a
> database query.
>
> Once I have an object id (and a mapfile metadata "id_attribute_string"
> "I_D|string") is it possible to call a project with something like:
>
> myproject.php?id=123
>
> and recentering the map with a certain scale?
>
> Or, if not, is there a way to retrieve coordinates of an object starting
> from an id and calling the project with
>
> myproject.php?recenter_bbox=23,45,56,70
>
> This solution would be probably better.
>
> Thanks in advance
>
> Regards
>
> Valerio
>
> _______________________________________________
> Cartoweb-users mailing list
> Cartoweb-users at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/cartoweb-users
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: emmanuel.belo.vcf
Type: text/x-vcard
Size: 337 bytes
Desc: not available
Url : http://lists.maptools.org/pipermail/cartoweb-users/attachments/20060316/6dd4d77d/emmanuel.belo.vcf
More information about the Cartoweb-users
mailing list