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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T13:50:31+00:00 2026-05-27T13:50:31+00:00

I have a menu which has a submenu. the submenu appears when i hover

  • 0

I have a menu which has a submenu. the submenu appears when i hover the main menu, but as soon as i try to go down to the submenu it disappears most of the time. Only if i’m very fast I’m able to get to it before it disappears.

HTML:

 <header>   
<div class="wrapper">
        <a href="#" id="logo" class="fl"><img src="images/logo.png" width="125" height="20" alt=""></a>
        <nav class="fl">
            <ul >
                <li> <a href="#" class="selected">Target Groups</a>
                <ul>
                    <li><a href="">Manage Target Groups</a></li>
                    <li><a href="">Create Target Group</a></li>
                </ul>   
                </li>
                <li><a href="#">Activity</a></li>
                <li><a href="#">Reports</a></li>
                <li><a href="#">Settings</a></li>
                <li><a href="#">Admin</a></li>
            </ul>
        </nav>
            </div>
            <!-- end .wrapper -->
    </header>

CSS:

header{
margin-top: 30px;
background: url(../images/header-bg.png) no-repeat; 
width: 942px;
height: 76px;
padding: 27px 25px 5px;
}
header .wrapper{
    border-bottom: 1px solid #e5e5e5;
    float:left;
    width: 862px;
    padding: 0 40px 5px;        
    position:relative;
}
header nav{
    margin-left: 45px;          
}
header nav ul{
    z-index: 100;
}
header nav ul li{
    display: inline;    
    margin-right: 35px;
    line-height: 20px;
    z-index: 100;
}
header nav ul li ul{
    display: none;
    position:absolute;      
    width: 962px;
    left: 0;
    top: 40px;  
}

header nav ul li ul li{
    float: left;    
}

header nav ul li:hover ul{
    display:block;  
}
header nav ul li a{
    font-size:16px;
    color: #5b666a;
    text-decoration: none;  
    padding: 5px 10px;
}
header nav ul li a.selected,header nav ul li a:hover{
    background: #657073;
    color: white;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    border-radius: 5px; 
}

I’m really stuck, please help…

  • 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-27T13:50:32+00:00Added an answer on May 27, 2026 at 1:50 pm

    In order to achieve what you want, it’s better to use padding-top for your submenu, instead of absolute positioning (with the latter you’ll end up with ’empty’ space between menu and submenu, causing mouseout):

    http://jsfiddle.net/BAzx7/

    EDIT: And I added position:relative; to ul li, and a lower z-index to ul li ul, otherwise the submenu would be over the main menu – and disable it…

    http://jsfiddle.net/BAzx7/1/

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

Sidebar

Related Questions

I have a JQuery drop down menu which has animated when we hover the
I have a menu bar which has several submenu items. The homepage contains a
I have a menu div which has a dark background. Inside it, I have
I have a web system which has a classical parent-children menu saved in a
I have a form which is a mdicontainer and has a menu strip at
I have a asp:menu object which I set up to use a SiteMapDataSource but
I have an application that has a top level navigation menu which consists of
I have a menu in which only one item has a sublist. Here is
I have a menu which has an item for each value in an enum.
I have a menu which has sub-menus and I have defined it as such:

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.