Passing a string to "aoColumns"

Passing a string to "aoColumns"

maliwikmaliwik Posts: 55Questions: 5Answers: 1
edited July 2011 in General
I have a table that has dynamic columns and I'm wondering if there's an easy way to pass a string to "aoColumns" to set the classes? Like have an element with an array as its text and pass $("#element").text() to "aoColumns". This doesn't work, but I'm wondering if there is a similar, simple solution to this problem.

I have three columns that are static that don't change and are on everything that I pass { "sClass": "columnProductItemID", "bVisible": false }, { "sClass": "columnProductItemQuantity", "sWidth": "100px", "bSortable": false }, { "sClass": "columnProductItemNumber" } to the table.

But then there can be up to 20 additional columns after those first three with further information that I want to be able to set the classes on as well.

Is this possible?
This discussion has been closed.