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 4005664
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T08:25:16+00:00 2026-05-20T08:25:16+00:00

Given the existing buttons HTML: <div id=MB> <ul class=list> <li id=post-5><a href=#post-5>5</a></li> <li id=post-4><a

  • 0

Given the existing “buttons”

HTML:

 <div id="MB">
    <ul class="list">
       <li id="post-5"><a href="#post-5">5</a></li>
       <li id="post-4"><a href="#post-4">4</a></li>
       <li id="post-3"><a href="#post-3">3</a></li>
       <li id="post-2"><a href="#post-2">2</a></li>
       <li id="post-1"><a href="#post-1">1</a></li>
    </ul> 
 </div>

CSS:

  #MB .list li a {
        float:left;
        color:#333;
        background:#f6f6f6;
        border:1px solid #eaeaea;
        border-right:none;
        padding:0 8px;
        }

   #MB .list li a:hover,
   #MB .list li a:focus {
        color:#fff;
        border:1px solid #333333;
        border-right:none;
        background:#404040;
        text-decoration:none;
        }

I’d like to simulate “hover” automatically on each button, sequentially, every n seconds.

This means that every n seconds a button is “hovered” (changing color etc), at next interval is “turned off” and the following button will “turn on” and so on…

  • 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-05-20T08:25:17+00:00Added an answer on May 20, 2026 at 8:25 am
    #MB .list a:hover,
    #MB .list a:focus,
    #MB .list .active a {
      /* hover styles */
    }
    

    (I’ve simplified your selectors a bit, I would also suggest trying to remove the outer div as these are often unnecessary and the ul alone is enough)

    Javascript hover:

    function setHover() {
        if ($('#MB .list .active').next().length) {
            $('#MB .list .active').next().addClass('active').end().removeClass('active');
        } else {
            $('#MB .list .active').removeClass('active');
            $('#MB .list li:first-child').addClass('active');
        }
    }
    
    setInterval(setHover, 1000);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to insert given text to existing pdf at X,Y location provided. I
I am running the following feature: Scenario: viewing existing images Given I am on
I have been given the task of adding functionality to an existing IIS 6.0
How can i filter the link given in link to existing content. As in
i need to check existing of Character (*,&,$) in Given String using python command
How to find potentially duplicate files in a given directory? Is there some existing
Given this method to work on a HTML page in a webbrowser: bool semaphoreForDocCompletedEvent;
I am facing this problem that buttons in android are not clickable when given
In an ordinary document list in SharePoint 2010 there are two buttons for adding
I'm making a basic multiple choice game. I have an existing database given the

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.