Solved

Floating menus overlapping !

Posted on 2010-09-07
3
560 Views
Last Modified: 2012-05-10
Hi


I have a 4x3 table of images.
When the user move the mouse over an image, a floating menu will appear so the user can select a menu item.

The code is working fine if I only have one cell.

However, I have a 12 adjacent cells in a 3x4 table. The problem is when the user move the mouse in order to select a floating menu item, the mouse eventually will move over another cell (image) and will cause the other cell to show its floating menu.

Is there a way to avoid that? like to disable all the other floating menus if there is an open menu?  

I put the whole project together in one zip file. You can unzip it and figure out the problem!


    problem.zip

Not to be rude, but PLEASE AVOID "COPY AND PASTE LINKS" ANSWERS!
0
Comment
Question by:HandyManny
  • 2
3 Comments
 
LVL 18

Expert Comment

by:Matthew Kelly
ID: 33622748
Do you need the 2 second timeout?

If you change: var timeout = 2000; to var timeout = 0;

It will only display one at a time.
0
 

Author Comment

by:HandyManny
ID: 33623817
If I set the timeout = 0 the user won't able to catch the floating menu!
0
 

Accepted Solution

by:
HandyManny earned 0 total points
ID: 33623861
I found the solution and it is so simple!
I just added a flag which equals 0 initially.
When I open a menu I check if the flag value = 0, in that case I put flag = 1 and open the floating menu. otherwise I do not open the floating menu.
When I close a menu I put the flag value = 0 again!

I have attached the same file after applying the solution

problem.zip
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Host asp.net pages 5 33
Converting dates in JavaScript 2 31
How to make footer stick to bottom 9 27
Best way to minify CSS with out breaking it 7 35
Creating a CSS block that only applies to printing By default, all of your CSS applies to every possible view of your page - whether on screen, printed, landscape, touch-screen, or whatever.  You can, however, add CSS that only applies under certai…
Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer …
In this tutorial viewers will learn how to define a gradient in CSS. Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Gradient. Define the background as "linear-gradient(to right, #ee3668, black)". Ensure you …
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …

815 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now