Add css class or id to toolbar item in xml data

Hi,

I’m trying to add an css class or an id to an toolbar item. The best way for me would be to define it in the xml data like:

Or is it possible to add the id to the HTML Tag?

Because I need a difference between a button and a buttonSelect. The css-class is for both the same “dhx_toolbar_btn” so I could not differ between them.
In a second step I would like to add a special background to a special toolbar item.

Thank you for your help

Dirk

Hi,

There is not possibility to add className for an item.

To add id to html tag of a select button you may use the following approach:

toolbar.forEachItem(function(itemId){
if (toolbar.getType(itemId)== “buttonSelect”) {
toolbar.objPull[toolbar.idPrefix+itemId].obj.id = itemId;
}
});