PDA

View Full Version : apply a style to ALL links EXCEPT...



belledumonde
05 Sep 2006, 06:25 AM
i have this css declaration:


a:active {
position: relative;
right: -1px;
bottom: -1px;
}

and i want it to apply to ALL links EXCEPT a img UNLESS the link has a class of "image".

this is because i'm using lightbox, and when the corner [ x ] is clicked on to close, it keeps moving and it won't close so you're stuck in the lightbox. i was thinking of making the [ x ] bigger but that ruins the image. then i tried applying different position declarations on a.image but that didn't work, i was thinking of selecting each link by contextual selectors except a.image but that just bloats my CSS.

so can this be accomplished with cross-browser compatible CSS or would it be more efficient to use a very short JS script??

help is much appreciated! :)