[OpenLayers-Users] attribute based styles

christopher.schmidt at nokia.com christopher.schmidt at nokia.com
Fri Sep 23 18:25:45 EDT 2011


On Sep 23, 2011, at 6:15 PM, ext Puneet Kishor wrote:
> 
> and the layer definition is 
> 
>    var lyr = new OpenLayers.Layer.Vector(
>        "a layer", {
>            style: {
>                "strokeWidth": 1, 
>                "strokeColor": "#ff0000", 
>                "fillColor": "#ff0000", 
>                "fillOpacity": "${opacity}", 
>                "pointRadius": "${radius}"
>            }
>        }
>    );
> 
> I was expecting the points to be rendered with the radius and opacity values for each feature. But not so. What am I doing wrong?

s/style:/styleMap: new OpenLayers.StyleMap({'strokWidth':, etc.})/

-- Chris

> --
> Puneet Kishor_______________________________________________
> Users mailing list
> Users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/openlayers-users



More information about the Users mailing list