Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Sep 2009
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    jQuery Pop Up Problem

    Hello there,

    I am new to jQuery and I am working on a website with some smooth effects.

    I want to pop up a <div> when the mouse is over the link. If the mouse isn't anymore over the link the <div> should hide.

    At the moment when the mouse is over the link the <div> appears, but it doesn't disappear when the mouse isn't over the link anymore.

    Code:
    $(".abouthover").hide();
    		$(".about").hover(function(){
    			$(".abouthover").slideToggle("slow");
    		});
    What can I do that the <div> disappears when the mouse isn't over the link anymore.

  • #2
    UE Antagonizer Fumigator's Avatar
    Join Date
    Dec 2005
    Location
    Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
    Posts
    7,691
    Thanks
    42
    Thanked 637 Times in 625 Posts
    The hover function takes two arguments-- the first is a function that describes what to do when the mouse moves into the element, the second is a function that describes what to do when the mouse moves out of the element.

    You may be interested in using a plugin that has done all the work for you-- I've used this one and like it:

    http://plugins.learningjquery.com/cluetip/demo/


  •  

    Tags for this Thread

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •