CSS Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Iron Speed
Go Back   Dev Shed ForumsWeb DesignCSS Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old August 19th, 2003, 03:16 PM
stodge stodge is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2000
Posts: 61 stodge User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 9
CSS problem when mouse hovers over link - doesn't always work

I'm having a problem with CSS on my site. I want links to change color and be underlined when the cursor moves over the link. It seems to work for some links but not others. I've tried this with both Mozilla 1.4 and IE6 and they both exhibit the same problem.

This is my site:

http://pixellent.stodge.net/wiki/vi...w&page=HomePage

And this is the CSS code I have:

Code:
a:link {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	color: #5F7383;
	text-decoration: none;
}
a:hover {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	color: #006A92;
	text-decoration: underline;
}
a:visited {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	color: #5F7383;
	text-decoration: none;
}


Can anyone see any obvious mistakes?

Thanks

Reply With Quote
  #2  
Old August 19th, 2003, 03:36 PM
knew youzr knew youzr is offline
The New User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: CA, USA
Posts: 109 knew youzr User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
CSS stands for Cascading Style Sheets. This means that as you go down the priority order, code can be overriden. This is what is happening here. I don't know if you noticed but all the links that work are the ones you have NOT visited b4, and all the ones that DONT work are the ones you have visited. The reason this occurs is because your a:visited is overriding your a:hover. To solve is simple. Move a:visited above a:hover, and below a:link, and all should work .

Hope that helps,
--Neil

Reply With Quote
  #3  
Old August 19th, 2003, 03:43 PM
stodge stodge is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2000
Posts: 61 stodge User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 9
Well I'll be.....

How simple was that!! lol

Thanks - appreciate it

Reply With Quote
  #4  
Old August 20th, 2003, 12:04 AM
knew youzr knew youzr is offline
The New User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: CA, USA
Posts: 109 knew youzr User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Haha, yeah, I once had that problem too... Just always remember, the order is link,visited,hover,active...

--Neil

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignCSS Help > CSS problem when mouse hovers over link - doesn't always work


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway