This week's book giveaway is in the Java 8 forum.
We're giving away four copies of Java 8 in Action and have Raoul-Gabriel Urma, Mario Fusco, and Alan Mycroft on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes Close DIV Popup When it Looses Focus Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Close DIV Popup When it Looses Focus" Watch "Close DIV Popup When it Looses Focus" New topic
Author

Close DIV Popup When it Looses Focus

Steve Dyke
Ranch Hand

Joined: Nov 16, 2004
Posts: 1391
I am using a link:hover to open a DIV using jQuery to load DIV with a table of options.

I need this DIV to stay displayed only while the cursor is within the boundries of the DIV.

I have tried to set onmouseout event to DIV that gets loaded but the DIV disappears(I suppose the onmouseout is fired) when I move the mouse from the calling link to the option table.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60082
    
  65

Check out .hover().


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Steve Dyke
Ranch Hand

Joined: Nov 16, 2004
Posts: 1391
Bear Bibeault wrote:Check out .hover().


The following works great when I run it by itself. However, when I load it into a DIV tag using jQuery.load the hover will display the option correctly but when I move the cursor off of the hover item to move down the option list the options disappear.

Steve Dyke
Ranch Hand

Joined: Nov 16, 2004
Posts: 1391
I figured it out. I put the hover on the ul instead of the li tag.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Close DIV Popup When it Looses Focus
 
Similar Threads
Progress GIF Just Displays but No Animation
100% height does not work
DHTML menu problems, keeps going and going...
Positioning DIVs
Unwanted Scrollbars