[OpenLayers-Users] Vector StyleMap labels with HTML tags (is it possible?)

Andreas Hocevar ahocevar at opengeo.org
Tue Aug 11 09:17:31 EDT 2009


Hi,

Milan Antonovic wrote:
> I would like some explanation about StyleMap with labels, before OL
> 2.8 I used to create popups with transparent background to create labels.
> But now I tried to use the new StyleMap - label option.
>
> During my tests I understand that I cannot do somthing like this:
>
>   label : "<h2>${value}</h2><br>${name}",
>
> Is there an other way to format labels with html tags using the label
> option?

Unfortunately not. The labels are rendered using SVG/VML/Canvas, and you
cannot provide markup for the label text.

Regards,
Andreas.

-- 
Andreas Hocevar
OpenGeo - http://opengeo.org/
Expert service straight from the developers.




More information about the Users mailing list