Need some help to lock a column background to be different than others, even after sort

Need some help to lock a column background to be different than others, even after sort

hwittenhwitten Posts: 2Questions: 0Answers: 0
edited March 2012 in DataTables 1.9
New to DataTables and still digging/searching in forum and docs but have not found (yet) how to address my problem. I'm hoping that someone can point me in a direction that will help me to solve.

I have a parts list of 8 columns and I want the first column background to be always white because a thumbnail is used and all the images have a white background so white column background would blend in nicely.

I set the selected css to white so after sorting on the first column it looks perfect but I have to do an initial sort on the second column.

What I want to achieve is that first column background is always white and all others, even sorted ones stay normal. This I can handle via css but how to keep white at all times for the first column is my stumbling block.

Is it even possible?

Here is my sample prototype that I've arrived at using one of the examples as a starting point.

http://shop.rareparts.com/smtp/tlist1.html

BTW, thank you VERY much for this excellent piece of software.

Replies

  • hwittenhwitten Posts: 2Questions: 0Answers: 0
    edited March 2012
    Found it.

    Added aoColumnDefs for sClass on the column and a css to keep it white.

    On to production testing.

    Edit:
    Well, not quite there. Loose the white on a sort now but at least I'm on track, sort of, I think.
    Edit2:
    Added some more css and got it. Now off to coding for production for real.
This discussion has been closed.