473,399 Members | 3,106 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

Div Drop Down Menu

I am taking a Javascript course online. We are learning to create
drop-down menus with <div> layers. The problem is that the way the
books teachers us to get the dropdown menu to work you have to click
the link once and twice to get rid of the menu. I am doing my final
project and I want to use the
OnMouseOver() function to get the menu open. The only problem is when
I do OnMouseOver on the link it opens the menu but when I go to click
something on the menu the menu disappears because my mouse isn't over
the original link anymore. Is there anyway to keep that menu open even
after I leave the link? I don't need exact code since this is my
project and I don't need anybody to do my homework. I just would
appreciate a point in the right direction.
Jul 23 '05 #1
3 5344
In article <ce**************************@posting.google.com >,
co*******@mix-net.net enlightened us with...
I am taking a Javascript course online. We are learning to create
drop-down menus with <div> layers. The problem is that the way the
books teachers us to get the dropdown menu to work you have to click
the link once and twice to get rid of the menu. I am doing my final
project and I want to use the
OnMouseOver() function to get the menu open. The only problem is when
I do OnMouseOver on the link it opens the menu but when I go to click
something on the menu the menu disappears because my mouse isn't over
the original link anymore. Is there anyway to keep that menu open even
after I leave the link? I don't need exact code since this is my
project and I don't need anybody to do my homework. I just would
appreciate a point in the right direction.


hints:
onMouseOut should close main menu.
setTimeout should be in the onMouseOut handler to keep open for a couple
seconds.
onMouseOver of a submenu should clear main timeOut so menu doesn't
close, then invoke it's own close with mouseOut/timeout.

--
--
~kaeli~
The Bermuda Triangle got tired of warm weather. It moved to
Finland. Now Santa Claus is missing.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #2
On 19 Apr 2004 11:15:48 -0700, Mark Constant <co*******@mix-net.net> wrote:

01234567890123456789012345678901234567890123456789 0123456789012345678912
I am taking a Javascript course online. We are learning to create
drop-down menus with <div> layers. The problem is that the way the books
teachers us to get the dropdown menu to work you have to click the link
once and twice to get rid of the menu. I am doing my final project and I
want to use the OnMouseOver() function to get the menu
Sorry to nit-pick, but it's the "onmouseover event" or "onmouseover
intrinsic event".
open. The only problem is when I do OnMouseOver on the link it opens the
menu but when I go to click something on the menu the menu disappears
because my mouse isn't over the original link anymore. Is there anyway
to keep that menu open even after I leave the link? I don't need exact
code since this is my project and I don't need anybody to do my
homework. I just would appreciate a point in the right direction.


An alternative approach to the one Kaeli suggested is to extend the box
(CSS term) that contains the link so that the mouse doesn't actually leave
the link area. It is a little more tricky, but will probably produce
better results.

Good luck,
Mike

--
Michael Winter
M.******@blueyonder.co.invalid (replace ".invalid" with ".uk" to reply)
Jul 23 '05 #3
Michael Winter <M.******@blueyonder.co.invalid> wrote in message news:<op**************@news-text.blueyonder.co.uk>...
On 19 Apr 2004 11:15:48 -0700, Mark Constant <co*******@mix-net.net> wrote:

01234567890123456789012345678901234567890123456789 0123456789012345678912
I am taking a Javascript course online. We are learning to create
drop-down menus with <div> layers. The problem is that the way the books
teachers us to get the dropdown menu to work you have to click the link
once and twice to get rid of the menu. I am doing my final project and I
want to use the OnMouseOver() function to get the menu


Sorry to nit-pick, but it's the "onmouseover event" or "onmouseover
intrinsic event".
open. The only problem is when I do OnMouseOver on the link it opens the
menu but when I go to click something on the menu the menu disappears
because my mouse isn't over the original link anymore. Is there anyway
to keep that menu open even after I leave the link? I don't need exact
code since this is my project and I don't need anybody to do my
homework. I just would appreciate a point in the right direction.


An alternative approach to the one Kaeli suggested is to extend the box
(CSS term) that contains the link so that the mouse doesn't actually leave
the link area. It is a little more tricky, but will probably produce
better results.

Good luck,
Mike

Thank you for the suggestion. I ended up using Kaeli hints last night
and got it working. Sorry for calling it a function(). I have taken
enough programming languages that I should atleast make sure that I
use the right terminology.
Jul 23 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: KK | last post by:
Drop-down menus are the hottest thing since Wonder Bread but . . . 1. Alot of people put them in the they-look-nice-but-you-cant-code-them-right-so-they-always-look-messed-up category (a la...
10
by: Haines Brown | last post by:
I've implemented the horizontal drop down menu discussed recently in this newsgroup, and it works nicely under Galeon and Mozilla, but not IE 5.0. Here are the problems: Under IE 5.0, the...
0
by: vikram.cvk | last post by:
Hello Experts, Im trying to design a CSS vertical drop down menu which should have the following functionality. Home About Us | -->Overview
2
by: hemanth.singamsetty | last post by:
Hello there, I've a drop down menu (created using CSS & Javascript -- see code below). My problem is, whenever I click a link on the menu the new page replaces the current page (and the menu...
4
by: simon.cigoj | last post by:
I have an javascript made menu and some forms with the dropdown element. When the menu opens and scrolls down the drop down is displeyed over the menu and obscures the menu choices. I have this...
1
by: phpnewb | last post by:
Hi, I know i'm doing it wrong, but I'm using a while loop right now to create several instances of a drop down menu. It gives me undesirable results. Can you tell me the right way to do it. Below are...
3
by: rsteph | last post by:
I have a javascript drop down menu that I borrowed from a website. It utilizes a little .css to help with formatting. The menu works great, and on all 3 of the browsers I'm concerned about; but I am...
4
by: TycoonUK | last post by:
Hi, As I do not have IE7 on my computer, I was wondering if there is a fault in my CSS Menu when using IE7. Please can someone look at my site - http://www.worldofmonopoly.co.uk and tell me...
1
by: Kaland | last post by:
Do the search engines follow links that are within forms (like the drop-down menu) so that those pages are indexed? Here is the code for a sample drop-down menu that I created. <form><select...
22
by: Archanak | last post by:
Hi, I am using 2-level CSS Drop Down Menu in my perl/CGI program. here is the code. #!c:/perl/bin/perl.exe use CGI qw(:standard);
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.