[OpenLayers-Users] How to get information on clicking on a polygon

Kusum kusum at infobase.in
Tue Mar 18 07:49:59 EDT 2008


thanks for the suggestion Stephen, I will try this

--------------------------------------------------
From: "Stephen Woodbridge" <woodbri at swoodbridge.com>
Sent: Monday, March 17, 2008 7:59 PM
To: "kusum" <kusum at infobase.in>
Cc: "Eric Lemoine" <eric.c2c at gmail.com>; <users at openlayers.org>
Subject: Re: [OpenLayers-Users] How to get information on clicking on apolygon> Try select astxt(the_geom) as wkt from mytable where ...
>
>
> kusum wrote:
>> this feature also uses points for a polygon and the problem is I have 
>> geometry of polygon and not the x y cordinates.
>> Please suggest any function if there in postgres  to convert the goemetry 
>> field to cordinates or any other method in openlayers if exists to 
>> highlight polygon using  goemetry.
>>
>> --------------------------------------------------
>> From: "Eric Lemoine" <eric.c2c at gmail.com>
>> Sent: Monday, March 17, 2008 3:30 PM
>> To: "kusum" <kusum at infobase.in>
>> Cc: <users at openlayers.org>
>> Subject: Re: [OpenLayers-Users] How to get information on clicking on a 
>> polygon
>>
>>> On Mon, Mar 17, 2008 at 8:07 AM, kusum <kusum at infobase.in> wrote:
>>>> Hi Eric
>>>>
>>>>  Thanks for replying back.
>>>>  I am able to fetch information from database. But the problem is that 
>>>> I am
>>>>  not able to highlight the polygon on map.
>>>>  To highlight it on map I need all the points in it. But the database I 
>>>> have
>>>>  in postgresql has field goem and I am not getting how to convert the 
>>>> goem
>>>>  field into coordinates so that I can get points to highlight the 
>>>> polygon on
>>>>  map.
>>>>
>>>>  Please suggest any function if there in postgres to convert the 
>>>> goemetry
>>>>  field to cordinates or any other method if exists to highlight polygon 
>>>> using
>>>>  goemetry.
>>> You have multiple solutions. One simple solution involves having the
>>> server send the wkt string and use OpenLayers.Format.WKT to parse that
>>> string.
>>>
>>> --
>>> Eric
>>
>>
>> _______________________________________________
>> Users mailing list
>> Users at openlayers.org
>> http://openlayers.org/mailman/listinfo/users
>
> 




More information about the Users mailing list