Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8313613
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T20:32:52+00:00 2026-06-08T20:32:52+00:00

Highlighting multiple elements on hover of one element is a common question. There are

  • 0

Highlighting multiple elements on hover of one element is a common question. There are a few similar questions on Stack about this issue, but it typically only deals with one tier of information.

For example: When I click this box, I would like to highlight another box.

I am wanting to add this functionality to three tiers of information, and have it work interchangeably.

See the fiddle here.

You can see it is working, but I am wondering if there is a way to do it better. For instance, it is ok when I have about 12 options for each tier, but what if it was 50, or 100? Is there a way to streamline it, so it would be easier to add multiple items in each tier without manually adding every class name relative to the id?

It seems like I could open up the explicit class names a bit by passing a variable to a function, but I don’t know how to get ALL of the class names of the hovered object, and check those against the class names in the other tiers.

Or, if you know of a plugin out there that does this magically?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T20:32:55+00:00Added an answer on June 8, 2026 at 8:32 pm

    That is about the best way to do it with jQuery. You can also do a similar effect with CSS and classes applied to parent elements.

    For instance:

    <div>
        <div class="bob">This is Bob.</div>
    </div>
    

    Then add a class to the parent element:

    <div class="show-bob">
        <div class="bob">This is Bob.</div>
    </div>
    

    Of course, the CSS is key here:

    .bob { opacity: 0.75 }
    .show-bob .bob { opacity: 1 }
    

    Sure, you need to add some CSS animation properties there for real feature parity, but you get the gist.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I was configuring syntax highlighting for my blog when I came across this problem.
There's no highlighting for Feature, Scenario, Given, When, Then, etc. keywords by default. Is
Is syntax highlighting there on vi?. I am sshing to an AIX box via
Is there a code editor that will allow copying of syntax highlighting to an
My code- $input = this text is for highlighting a text if it exists
Are there any specific examples or tutorials highlighting the use of Google Guava's Service
Is there any free system to write code with multiple users online in real
Possible Duplicate: Syntax highlighting code with Javascript I have noticed that Stack Overflow uses
is there way to remove drag highlighting within a GWT app without removing the
I want to implement in desktop application in java searching and highlighting multiple phrases

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.