[OpenLayers-Users] Re: Styling point features by attribute values

Rossko rossko at culzean.clara.co.uk
Thu Jun 16 15:54:36 EDT 2011


>
map.layers[1].styleMap.styles.default.defaultStyle.pointRadius='${Water_Leve}';
...
> I think that the attribute may have been registered as a string

What attribute?  To javascript '${Water_Leve}' is a string, pure and simple,
with a $ character, a { character, a W character, etc etc.

>  ... =parseFloat('${Water_Leve}');

It's still just a string, so parseFloat of a non-numeric string give result
NaN (Not a Number), just as it should.


--
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Styling-point-features-by-attribute-values-tp6483796p6484513.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.


More information about the Users mailing list