Depends if 2 items in your list will have the same background then you would use a class (think of a class as a group)
if every item in your list each has seperate then you would use ID (think of an ID and an individual name) use ID if its 1 use CLASS if its greater then 1 to be considered on the one page.... (used more then once on the one page....) Regards PWP ----- Original Message ----- From: "vwf" <[EMAIL PROTECTED]> To: <> Sent: Wednesday, September 13, 2006 9:08 PM Subject: [css-d] changing backgrounds in list items > On 13/09/2006 10:58, vwf wrote: >> I have a list of 6 items, and I want to associate a different image >> with >> each of the 6 items. Is there a smart/correct way to do this? Does >> someone know an example that has this implemented? > > Thank you all for the various suggestions. > > It seems that the straight-forward approach is the way to go: > simply add extra classes or id's for each of the elements. > I implemented it, and it works perfectly. > > One question: why would I prefer 'id' over 'class' selectors? > > ______________________________________________________________________ > css-discuss [EMAIL PROTECTED] > http://www.css-discuss.org/mailman/listinfo/css-d > IE7b2 testing hub -- http://css-discuss.incutio.com/?page=IE7 > List wiki/FAQ -- http://css-discuss.incutio.com/ > Supported by evolt.org -- http://www.evolt.org/help_support_evolt/ > ______________________________________________________________________ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7b2 testing hub -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/