Everything worked when I used same ID for more than one element, I thought both ID and CLASS are same as far as CSS is concerned -- and my design worked. About validation, who cares, in the beggining.
But seriously, thing is, one shouldn't use same ID for more than one element, and I think, for what ID stands for Identification; like you have an unique employee ID, or have unique driving license ID. Whereas every element may have same CLASS (it's like M size shirt of some brand which everyone can buy and wear), but not the same ID, that is specific to a element.
If you want to write reusable CSS for lots of elements, then write them in CLASS; not in ID.
Comments
Post a Comment