Row background image

Row background image

GawainGawain Posts: 5Questions: 1Answers: 0
edited September 2010 in General
Hi, I would like to have different backround images of table rows. The name of background image is saved in the database (for each record there is different image) .

I have written something like that (aData[0] doesn't work of course, i need to have the access to the name of image).
[code]
"fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) {
$('td:eq(1)', nRow).css("background-image", 'url(images/'+aData[0]+'.gif)');
return nRow;
}
[/code]

Can you suggest any method how to set the backgound image with CSS?

I use server-side method.

Thank you very much for answers
This discussion has been closed.