[OpenLayers-Users] How to perform spatial search

Imran Rajjad rajjad at gmail.com
Sun Jul 18 06:37:30 EDT 2010


HI,

I think you need to put in an html drop down list, you need to trigger a
function at an event occurent on this drop down list. Get the text and name
of layer, from which to search the feature from. The layer name should be in
drop down list. You need to programticaly generate a wfs with a cql filter
appended in the url . The response will contain the feature, you can get the
bounds of the feature, and simple use openlayers to zoom and pan to that
extent. I think you need to start looking for CQL filters, they will perform
the searching for you.

regards,
Imran
On Sun, Jul 18, 2010 at 2:43 PM, Jehanzeb Orakzai <
jehanzeb_orakzai at yahoo.com> wrote:

>   Hi,
>
> I am using OpenLayers for web mapping, GeoServer to serve maps as WMS and
> WFS & PostgreSql/PostGIS for database having spatial and non-spatial data.
>
> I have cities & school data as point in their respective tables in the
> database which are publish through GeoServer. School table is linked with
> cities using cityID.
>
> I want to develop a form that contains cities as text box and school as
> dropdown loaded from the database, so that a user can perform search on it
> and the map is zoomed to that particular area with non-spatial information
> display in a separate grid.
>
> I don’t know how to load the data in the combo box / dropdown from the DB
> using the above software stack and perform some searching. How to zoom to a
> particular location based on the criteria and display non-spatial data in
> grid.
>
> I need some guidelines or examples for the problem stated above.
>
> Can somebody help me in achieving this?
>
> Any help is appreciated.
>
> *Thank you,*
> *--*
> *Jehanzeb*
>
>
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
>


-- 
I.R
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20100718/b61c82c5/attachment.html


More information about the Users mailing list