Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

JavaScript Forum


You are currently viewing our JavaScript Forum as a guest. Please register to participate.
Login



Reply
Mouse-over un-linked underlining question
Old 11-04-2007, 08:59 AM Mouse-over un-linked underlining question
Average Talker

Posts: 21
Name: Paul
Trades: 0
I am using a javascript expandable vertical menu with CSS on a site under development (www.testplace.co.uk). My problem is that the top level menu is only underlined on mouse-over if there is a direct link to another page from that level. However, I want users to see that the menu is expandable EVEN IF there is no direct link from that level when they mouse-over on it.

The java code for the second set of menus is:

<dt onclick="javascript:show('smenu2');">Consultants</dt>
<dd id="smenu2">
<ul>
<li><a href="briantowers.php">Brian Towers </a></li>
<li><a href="janetoplis.php">Jane Toplis </a></li>
</ul>
</dd>

And the CSS governing the presentation of the menu is:

#menu dt {
cursor: pointer;
margin: 2px 0;;
height: 20px;
line-height: 20px;
text-align: left;
font-weight: bold;
border: 0px solid gray;
background: #d8d8d7;
}
#menu dd {
border: 0px solid gray;
}
#menu li {
text-align: left;
background: #d8d8d7;
}
#menu li a, #menu dt a {
color: #000;
text-decoration: none;
display: block;
border: 0 none;
height: 100%;
}
#menu li a:hover, #menu a:hover, #menu dt a:hover {
background: #d8d8d7;
color: #1D6D99;
text-decoration: underline;
}

What do I need to add in CSS or Java to get the unlinked 'Consultants' to underline and change colour on mouse-over?

KB
keelbolt is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 11-04-2007, 12:48 PM Re: Mouse-over un-linked underlining question
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
simplest way


onmouseover="this.className='underlined_class'" onmouseout="this.className='no_underline_class'"
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Reply     « Reply to Mouse-over un-linked underlining question
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.10281 seconds with 12 queries