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

  • SEARCH
  • Home
  • 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 659013
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T22:59:48+00:00 2026-05-13T22:59:48+00:00

I have this menu structure that is used to navigate through content slider panels.

  • 0

I have this menu structure that is used to navigate through content slider panels.

 <div id="menu">
  <ul>
    <li><a href="#1" class="cross-link highlight">Bliss Fine Foods</a></li>
    <li><a href="#2" class="cross-link">Menus</a></li>
    <li><a href="#3" class="cross-link">Wines</a></li>  
    <li><a href="#4" class="cross-link">News</a></li>   
    <li><a href="#5" class="cross-link">Contact Us</a></li> 
  </ul>
</div>

I would like to loop through these elements and remove the highlight class and then add the highlight class to the current / last clicked menu item.

Any ideas? Any help would be greatly appreciated.

Thanks

Jonathan

  • 1 1 Answer
  • 3 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-05-13T22:59:48+00:00Added an answer on May 13, 2026 at 10:59 pm

    May be so?

    $('#menu li a').click(function(){
      $('#menu li a').removeClass('highlight');
      $(this).addClass('highlight');
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this html structure <div class=top_menu> <ul> <li class=left><a href= class=family-filter>asdas</a></li> <li class=welcome>Welcome
Assuming I have this HTML structure: <ul class='menu'> <li> <div></div> <div> <div></div> <div> <a
I have a nested ul menu structure that starts off like this: <div id=left>
I have a menu structure that looks like this: HTML: <li> <a href=#page> <b>Recover
I have this ul menu: <ul id=superfish-1> <li class=active-trail><a href=# class=sf-depth-1 active>Inicio</a></li> <li class=trail><a
i have this html menu: <ul id='main'> <li class='active current' id='lighty'> <a href='/'>Lighty</a> <ul>
Greetings I have this structure: <ul id=list class=tabs> <li class=list><a href=#tab1>Dados do Responsável</font></a></li> <li
I have the menu structure like below, <div class=submenu> <ul class=treeview> <li class=submenu id=menu-item-5592
I'm developing a html with this structure div id=menuContainer> <div class = menu ui-accordion-header
I have this menu structure: http://jsfiddle.net/Rochefort/szL2C/ everything is ok. But i want, hover effect

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.