[OpenLayers-Users] Add popup to GML with marker!

Christopher Schmidt crschmidt at metacarta.com
Mon Dec 10 07:58:08 EST 2007


On Mon, Dec 10, 2007 at 12:28:51PM +0100, Walter Lorenzetti wrote:
> Hi everybody,
> 
> I've a problem with a GML layer:
> I add to my map a new GML layer and for to put a icon istead the normal
> vectorial circle
> I extend default vector layer style:
> 
>  var style_mark = OpenLayers.Util.extend({},
> OpenLayers.Feature.Vector.style['default']);
>      style_mark.graphicWidth = 16;
>      style_mark.graphicHeight = 16;
>      style_mark.graphicOpacity = 1;
>      style_mark.externalGraphic = "/webgis/openlayers/stable/icon.png";
> 
> Now I've to add I popup to this mark but I don't know I can...
> Is possible to do that or is necessary parser the GML file and put n
> markers with popup?

Looking at http://openlayers.org/dev/doc/examples.html, we see:

61
Open Popup on Layer.Vector
select-feature-openpopup.html
Using a Control.SelectFeature, open a popup on click. 

http://openlayers.org/dev/examples/select-feature-openpopup.html

Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Users mailing list