I think css precedence has got you down. As I remember it, ID selectors override class selectors (since id is more specific than class). Try using border: 3px solid red !important; or maybe the change the css selector to div.maindiv-hover { ... } and see if this fixes your problems. Look up css precedence for the exact order.
- [jQuery] Same code structure to affect two elements, but one doe... Cristian
- [jQuery] Re: Same code structure to affect two elements, bu... marr.adam