Computing.Net > Forums > Programming > to Jaap from Netherlands

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

to Jaap from Netherlands

Reply to Message Icon

Name: br1an
Date: March 5, 2003 at 03:14:36 Pacific
OS: Windows
CPU/Ram: 256
Comment:

Hi Jaap (and anyone who read this),
From your previous example abt the drop down menu, when the user point the mouse to the table cell, the drop down menu will come up with the colour that we specified in the CSS rules, right ? What do i need to change in the JavaScript so that when the user point to that cell, 2 things will happen:
-the cell will change its color
-the drop down menu will come up
(if you have not read my prev posting, just have a look at: www.national.com.au to have some idea what i'm talking about. It's about the nav bar that has a drop down menu if the user points his mouse on it).
If you already have that in mind, please let me know. I'm currently trying it. If you don't know, thats fine, i will find it out sooner or later.

Best regards,



Sponsored Link
Ads by Google

Response Number 1
Name: Jaap
Date: March 9, 2003 at 11:43:30 Pacific
Reply:

Hi BrIan,
sorry for the long waiting, I don't look on this forum every day. I took another look to the script, and have edited it for you. This is as good as i can get it for now (I'm 13 years old).
As I am building my (first) own site, i knew where to find the scripts you needed. And merged them together to get the desired result.
The site www.national.com.au uses gif files in the top of the menu, and some .js or .css files. I didn't :P

So here comes the new script.

<html>
<head>
<PRE>
<style type="text/css">
a:link {font= "Verdana, Arial, Helvetica, sans-serif" ; color="black"; text-decoration: none; size: 2}
a:visited {font= "Verdana, Arial, Helvetica, sans-serif" ; color="black"; text-decoration: none; size: 2}
a:hover {font= "Verdana, Arial, Helvetica, sans-serif" ; color="black"; text-decoration: none; size: 2}
</style><style>
body{font-family:verdana;}
table{font-size:80%;background:black}
A.menulink {display: block;width="100%"}
a{color:black;text-decoration:none;font:bold}
a:hover{color:orange}
td.menu0{background:red}
td.menu1{background:white}
td.menu2{background:blue}
table.menu
{
font-size:100%;
position:absolute;
visibility:hidden;
}
</style>
<script language="JavaScript">
function toonmenu(elmnt)
{
document.all(elmnt).style.visibility="visible"
}
function verstopmenu(elmnt)
{
document.all(elmnt).style.visibility="hidden"
}
</script>
<title>This page;
<tr bgcolor="red">
<td onmouseover="toonmenu('site1')" onmouseout="verstopmenu('site1')">
<a href="index.htm">Site 1</a><br />
<table class="menu" id="site1" width="100%">
<tr><td class="menu0" onmouseout="style.backgroundColor='red'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: red"><a href="pag1.htm">something</a></td></tr>
<tr><td class="menu0" onmouseout="style.backgroundColor='red'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: red"><a href="pag2.htm">something</a></td></tr>
<tr><td class="menu0" onmouseout="style.backgroundColor='red'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: red"><a href="pag3.htm">something</a></td></tr>
<tr><td class="menu0" onmouseout="style.backgroundColor='red'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: red"><a href="pag4.htm">hi</a></td></tr>
<tr><td class="menu0" onmouseout="style.backgroundColor='red'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: red"><a href="pag5.htm">bye</a></td></tr>
</table>
</td>

<td bgcolor="white" onmouseover="toonmenu('site2')" onmouseout="verstopmenu('site2')">
<a href="http://www.site2.nl">Site 2;<td class="menu1" onmouseout="style.backgroundColor='white'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: white"><a href="http://www.your-domain.ext/pag1.htm">Who</a></td></tr>
<tr><td class="menu1" onmouseout="style.backgroundColor='white'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: white"><a href="http://www.site2.nl/pag2.htm">What</a></td></tr>
<tr><td class="menu1" onmouseout="style.backgroundColor='white'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: white"><a href="http://www.site2.nl/pag3.htm">Where</a></td></tr>
<tr><td class="menu1" onmouseout="style.backgroundColor='white'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: white"><a href="http://www.site2.nl/pag4.htm">Why</a></td></tr>
<tr><td class="menu1" onmouseout="style.backgroundColor='white'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: white"><a href="http://www.site2.nl/pag5.htm">When</a></td></tr>
</table>
</td>

<td bgcolor="blue" onmouseover="toonmenu('site3')" onmouseout="verstopmenu('site3')">
<a href="http://www.site3.nl">Site 3;<td class="menu2" onmouseout="style.backgroundColor='blue'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: blue"><a href="http://www.site3.nl/pag1.htm">Who</a></td></tr>
<tr><td class="menu2" onmouseout="style.backgroundColor='blue'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: blue"><a href="http://www.site3.nl/pag2.htm">What</a></td></tr>
<tr><td class="menu2" onmouseout="style.backgroundColor='blue'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: blue"><a href="http://www.site3.nl/pag3.htm">Where</a></td></tr>
<tr><td class="menu2" onmouseout="style.backgroundColor='blue'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: blue"><a href="http://www.site3.nl/pag4.htm">Why</a></td></tr>
<tr><td class="menu2" onmouseout="style.backgroundColor='blue'; "
onmouseover="style.backgroundColor='yellow'; " style="BACKGROUND-COLOR: blue"><a href="http://www.site3.nl/pag5.htm">When</a></td></tr>
</table>
</td>
</table>
</PRE><P><P><P>
</html>


Greetz from Jaap


0
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: to Jaap from Netherlands

Batch file to copy from network dri www.computing.net/answers/programming/batch-file-to-copy-from-network-dri/14488.html

how to remove \ from variable www.computing.net/answers/programming/how-to-remove-from-variable/15757.html

Converting to and from binary. www.computing.net/answers/programming/converting-to-and-from-binary/5222.html