Home › Forums › Guriddo jqGrid JS › Help › Add Class to Column Header
This topic contains 6 replies, has 2 voices, and was last updated by guriddo.support 4 months, 2 weeks ago.
Is there a way to add styles or CSS classes to column headers? I’m trying to change the background color or font color of a column and I can do this in the data rows, but the column headers are different.
One possible solution is to use setLabel method. Look into the docs here
Guriddo Support Team
that works perfectly, thanks!
follow up question: do you have any ideas for group headers?
Again you will need to look at the docs for setGroupHeaders method
There is a option called className for the item, when grouping is set
that works fine for a class name, is there anything to add a style? I don’t see anything in the documentation.
Direct this is not supported, but it can be done after you set a certain class to this group.
By example if the class you set after calling the setGroupHeader has a name myfirstclass and the id of the grid is grid
then you can access the header element like this
Then you can do what you want with this element
You must be logged in to reply to this topic.
Stay connected with us in your favorite flavor!
Copyright 2014 TriRand LtdAll Rights ReservedRSS