开发者

How to assign a unique CSS id to each cell in a jqGrid?

开发者 https://www.devze.com 2023-02-04 08:15 出处:网络
It seems jqGrid is not assigning any CSS ids to cells by default. Any tips how to go about开发者_运维问答 it?

It seems jqGrid is not assigning any CSS ids to cells by default.

Any tips how to go about开发者_运维问答 it?

I notice I can assign classes per column as per the wiki, but I would like to add CSS ids.


Why jqGrid schould assign an additional CSS class for every cell if jqGrid not use the class? If you need to add a CSS class to some jqGrid cells you can use setCell method.

$("#list").jqGrid('setCell', id, colName, '', "someCssClass");

See modified demo for this old answer as an example.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号