Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-28-2012, 08:09 PM   PM User | #1
Strider64
New Coder

 
Join Date: Dec 2011
Posts: 33
Thanks: 4
Thanked 4 Times in 4 Posts
Strider64 is an unknown quantity at this point
Navigation Problem

I'm doing a website for a client: Black Hawk Ranch and I am having problem with the links:

I wand only an underline at the bottom of the navigation button, not all three lines like it is current doing.

Here's the HTML Code:
Code:
<div id="nav">
      <ul>
        <li><a href="index.html"><span class="nav-style subselected">Black Hawk Ranch <br />
          Pictures <br/>

          The Saga Continues</span></a></li>
        <li><a href="#"><span class="nav-style">Black Hawk Ranch <br />
          Excavating <br />
          Mid Michigan Service</span></a></li>
        <li><a href="the-kids.html"><span class="nav-style">Pictures of <br />
          the Kids<br />

          Life's Little Miracles</span></a></li>
        <li><a href="#"><span class="nav-style">Let's Talk <br />
          Politics <br />
          Articles &amp; Commentary</span></a></li>
        <li><a href="#"><span class="nav-style">Ask <br />

          herbie.com <br />
          Advice from A to Z</span></a></li>
      </ul>
    </div>
Here is the CSS Code:
Code:
#nav ul li a {
	display: block;
	width: 200px;
	height: 50px;
	font-family: Verdana, Geneva, sans-serif;
		font-size: 12px;
		font-weight: bold;
		
		color: #fff;
		text-decoration: none;
		text-align: left;
	padding: 0px;
	margin: 0px;
}

#nav ul li a:hover {
		
	text-decoration: underline;
}
I've tried a few things, but either it separates the trees too much or drops them down. If someone would be point me in the right direction, I would very much appreciate it. It's probably a simple solution and I probably will go duh when I see the fix. LOL

Thanks John
Strider64 is offline   Reply With Quote
Old 01-28-2012, 08:13 PM   PM User | #2
Excavator
Master Coder


 
Excavator's Avatar
 
Join Date: Dec 2006
Location: Alaska
Posts: 9,410
Thanks: 22
Thanked 1,765 Times in 1,749 Posts
Excavator has a spectacular aura aboutExcavator has a spectacular aura aboutExcavator has a spectacular aura about
Hello Strider64,
Instead of underlining the text in your anchor, underline the anchor itself... like this -
Code:
#nav ul li a:hover {
		
	border-bottom: 1px solid #f00;
}
__________________
Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad
Excavator is offline   Reply With Quote
Users who have thanked Excavator for this post:
Strider64 (01-28-2012)
Old 01-28-2012, 09:35 PM   PM User | #3
Strider64
New Coder

 
Join Date: Dec 2011
Posts: 33
Thanks: 4
Thanked 4 Times in 4 Posts
Strider64 is an unknown quantity at this point
Thanks Again, that solved the problem.
Strider64 is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

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

Forum Jump


All times are GMT +1. The time now is 12:08 AM.


Advertisement
Log in to turn off these ads.