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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T14:23:58+00:00 2026-06-17T14:23:58+00:00

I am working on a custom menu in jQuery and learning as I go.

  • 0

I am working on a custom menu in jQuery and learning as I go. I was doing fine so far for the most part until I started the dropdown menu. A div in my dropdown overlaps my link and the link become unclickable. You will see what you mean when you test out the code. Any help is appreciated.
Here is a link to jsFiddle

Here is my CSS:

li {
    background-color: #ccc;
    position: relative;
    color: #fff;
    z-index: -2;
    float: left;
}
div.menu-item {
    background-color: #000;
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 10px;
    z-index: -1;
}
a.menu-text {
    display: block;
    color: #fff;
    margin: 0;
    padding: 10px;
    padding-bottom: 15px;
}
div.dropdown {
    display: none;
    position: absolute;
}
div.dropdown-item {
    position: relative;
    background-color: #1E4b55;
}
div.dropdown-item a {
    padding: 10px;
    padding-left: 15px;
    display: block;
    white-space: nowrap;
    color: #fff;
}
div.dropdown-left {
    height: 100%;
    width: 10px;
    background-color: #000;
    position: absolute;
    top: 0;
    left: 0;
}

Here is my HTML

<div>
    <ul>
        <li>
            <div class="menu-item"></div>
            <a class="menu-text" href="#">text</a>
            <div class="dropdown">
                <div class="dropdown-item"><div class="dropdown-left"></div><a href="#">item 1</a>

                </div>
                <div class="dropdown-item"><a href="#">item 2</a>

                </div>
                <div class="dropdown-item"><a href="#">item 3</a>

                </div>
            </div>
        </li>
        <li>
            <div class="menu-item"></div>
            <a class="menu-text" href="#">texttexttext</a>
        </li>
        <li>
            <div class="menu-item"></div>
            <a class="menu-text" href="#">tetexttexttexttexttexttexttextxt</a>
        </li>
    </ul>
</div>

And here is my javascript:

$(function () {
    $("li").hover(
    function () {
        $(this).find('div.menu-item').stop().animate({
            height: '100%'
        }, {
            duration: 700,
            specialEasing: {
                height: 'easeOutQuint'
            }
        });
        $(this).find('div.dropdown').slideDown();
    },

    function () {
        $(this).find('div.menu-item').stop().animate({
            height: '10px'
        }, 700);
        $(this).find('div.dropdown').stop().slideUp();
    });
    $("div.dropdown-item").hover(
        function(){
            $(this).find('div.dropdown-left').stop().animate({
                width: '100%'
            }, {
                duration: 700,
                specialEasing: {
                    width: 'easeOutQuint'
                }
            });
        },
        function(){
            $(this).find('div.dropdown-left').stop().animate({
                width: '10px'
            }, 500);
        }
    );
});
  • 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-17T14:24:00+00:00Added an answer on June 17, 2026 at 2:24 pm

    add

    div.dropdown-item a {
        position: relative;
    }
    

    http://jsfiddle.net/Y9knm/2/

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

Sidebar

Related Questions

I'm working on this custom select menu that is part of a forms plugin
I am working on a Wordpress-Design and i want to creat a Custom Menu.
I have a custom menu in jQuery that apparently doesn't work with IE 8
I'm working on a custom navigation menu, I've added the following property within my
I want to create a custom WPF dropdown menu, so I created a User
I'm creating a custom control in wxWidgets that displays a menu as part of
I have a custom Action Helper that is working fine. It's generating a dynamic
I am working on a custom context menu in Flex4. The context menu itself
i am working in html for a custom drop down menu. I want to
I have a sidebar toggle menu in WordPress which is working fine, however when

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.