I am building a site using Openlayers module in drupal 7. In my map page I have prepared my layers using views (OpenLayers Data Overlay) and added a field for the fill color of the polygons (it's a hex value). In my custom style for the layer I added the corresponding value (${field_color_style}) in the fill color text box but I cannot get it work.I keep getting the default black fill color.Is there any other way to achieve this? How can I debug such problem? Anyone else having implemented such fuctionality using drupal 7 and openlayers module?
0
votes
2 Answers
0
votes
0
votes
It happened to me and the problem is that, since OpenLayers beta 9, the rendering of the fields has changed, it's not using the raw value of the field, but the full row rendering. You must disable all the HTML element by selecting None in the Style setting fieldset of the field in Views or you might get a mix of HTML with the raw value of the field that than doesn't work in the map.