The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Highlighting all of a class upon hover

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #36104

    I have a container

    and inside it there are a number of elements. Each has a class and these classes can be absolutely anything. When I hover the cursor over one element, I want all elements inside the container with the same class to have the same css applied as the one being hovered.
    I would really prefer this to be completely CSS.
    Is there a way to do this?

    Hi Varkor!

    Off the top of my head, I’d have to say no. You’ll need some javascript to do this. But maybe there is some trick that someone else might know… but I have my doubts.

    This demo is how I’d do it with jQuery.


    it’d be easy with jquery but I think impossible with only css… You could do something to all of them when you over over the container of course, but that’s not really what you are asking for.


    Ah, that’s what I kind of suspected…
    Thanks for helping out!

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘CSS’ is closed to new topics and replies.