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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T17:15:01+00:00 2026-06-02T17:15:01+00:00

I am attempting to using jQuery make the height of a particular div expand

  • 0

I am attempting to using jQuery make the height of a particular div expand whenever a mouse is hovering over it so I can make a menu out of it. But for some reason it always cycles up and down twice as my mouse is hover over it instead of just the one time I want it to. Here’s a copy of my code that contains the error.

<div id="Container">
        <div id="Headeritem">
            <div id="NavBaritem">
              <div id="Nav3item">
                <div id="NavExpand3item"><a href="#" class="NavTextitem">Ministries</a></div>
              </div>
            </div>
          </div>
        <script type="text/javascript" src="jquery-1.4.2.min.js"></script> 
        <script type="text/javascript">
          <!--Script for NavBar Control
          $(document).ready(function(e) {
            <!--Script for AboutNE DropDown//-->
            $('#NavExpand3item').hover(
                function () {
                    $('#NavExpand3item').animate({
                        'height':'200px'
                    }, 300);
                },
                function () {
                    $('#NavExpand3item').animate({
                        'height':'0px'
                    }, 300);
                }
            );
          });

          //-->
         </script>
  </div>

I really just want to know how I can prevent my menu from cycling twice, here is a link to a site. I hope someone will be able to help me.

Thank You,

Mo

  • 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-02T17:15:04+00:00Added an answer on June 2, 2026 at 5:15 pm

    @Francisc is pretty much correct.

    http://jsfiddle.net/4cVSq/

    What’s happening is(i think), when you mousover the text it expands the div and when your mouse encounters the div as it expands, it counts that as another hover.

    You have two options. the one a linked before. or this one.

    http://jsfiddle.net/4cVSq/2/

    You can give the outer div a height, or you can put the mouseover for the inner div, while still animating the outer div. I think the first one is what you want, since this looks like you are planning on making it into a menu.

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

Sidebar

Related Questions

I'm attempting to get the height of an element using jQuery, but am receiving
I am attempting to make an element shake upon hover without using jQuery UI
I'm using this plugin http://www.fyneworks.com/jquery/star-rating/#tab-Testing . I was attempting to make a client-side validation
Using Jquery 1.6.4. I'm attempting to use css to give my app a clue
I am attempting to clone fields in a form using Jquery. I'm trying to
I am attempting to use livequery. I unfortunately am stuck using jquery 1.2.6. This
I am attempting to prevent default anchor behavior in Safari using the jQuery library.
I am attempting to pase a a JSON data using the JQuery getJSON function.
In my MVC view (using VS 2012 RC), I'm attempting to use jQuery to
I'm attempting to create divs in an table using jQuery. The table represents a

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.