iPowerWeb Hosting
 
Home Register FAQ Members List Calendar Search Today's Posts Mark Forums Read Web Directory

Go Back   Webmaster Forum > Designing and Developing Websites > Web Design

Web Design Discussions and help on Website Design, HTML, CSS, xHTML, DHTML, etc...

Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 03-16-2007, 03:30 PM
lame.crusher lame.crusher is offline
Persona Non Grata
 
Join Date: Mar 2007
Posts: 127
iTrader: (0)
lame.crusher is on a distinguished road
Default Hyperlink changes colour if hovered only first time

I use expression web to design my site. On FILE - Properties - Formatting, I select a colour for hovered hyperlinks. The style that is created is shown below.
However it is only working if the link has never been visited. After the first visit the colour does not show any more upon hovering. Any ideas?


.style75 {
font-size: 8pt;
}
a:hover {
color: #AE2836;
}
a:visited {
color: #336CA3;
}
Reply With Quote
Sponsored Links
Register and sign in to hide this ad block

  #2 (permalink)  
Old 03-17-2007, 12:00 AM
chopstickles chopstickles is offline
WMG Resident Alien

Recent Blog: I hate spam!
 
Join Date: Mar 2007
Location: Makati City, Philippines
Posts: 74
iTrader: (0)
chopstickles is on a distinguished road
Default

It doesn't work because a:hover should come after a:visited, not the other way around.

Reply With Quote
  #3 (permalink)  
Old 03-17-2007, 08:47 AM
spid4r spid4r is offline
WMG Resident Alien
 
Join Date: Mar 2007
Posts: 229
iTrader: (0)
spid4r is on a distinguished road
Default

The order you use for your rules is important. Each of the pseudo classes has equal weight, so the last one coded overrides the earlier ones. Since :visited follows :hover in the rules, once you visit the site, the :visited will control.

Put your rules in this order:
:link
:visited
:focus
:hover
:active

Just tell me if it works ! Cheers
Reply With Quote
  #4 (permalink)  
Old 03-17-2007, 08:54 AM
technoguy technoguy is offline
WMG Citizen
 
Join Date: Mar 2007
Posts: 436
iTrader: (0)
technoguy is on a distinguished road
Default

This is my working code I am using at my projects sometimes hope it helps

HTML Code:
a:link {
font-weight: normal;
color: #0033FF;
text-decoration: underline}
a:visited {
font-weight: normal;
color: #990000;
text-decoration: underline}
a:hover {
font-weight: bold;
color: #FF0000;
text-decoration: none;
background-color: #CCCCCC;
border: 1px solid #000000;
padding: 4px;
}
a:active {
font-weight: bold;
color: #FFFFFF;
text-decoration: none;
background-color: #990000;
padding: 4px;
border: 1px solid #000000;
}
Reply With Quote
  #5 (permalink)  
Old 03-18-2007, 03:13 AM
lame.crusher lame.crusher is offline
Persona Non Grata
 
Join Date: Mar 2007
Posts: 127
iTrader: (0)
lame.crusher is on a distinguished road
Default

Done it. Cleaned everything up and redone it. Thanks a lot to spid4r and technoguy , you both got a green rep from me .

Cheers
Reply With Quote
  #6 (permalink)  
Old 03-23-2007, 06:18 AM
creek23 creek23 is offline
WMG Deputy Sheriff
 
Join Date: Mar 2007
Posts: 290
iTrader: (0)
creek23 is on a distinguished road
Default

Quote:
Originally Posted by lame.crusher View Post
However it is only working if the link has never been visited. After the first visit the colour does not show any more upon hovering. Any ideas?
This is caused by Temporary Internet Files, and browser's History. It displays that the link is already visited.

(Well, I dont know if that helped. My philosophy is that, if you know what's going on, then you'll know what to do and know what you've been doing wrong.)
Reply With Quote
  #7 (permalink)  
Old 03-23-2007, 06:22 AM
technoguy technoguy is offline
WMG Citizen
 
Join Date: Mar 2007
Posts: 436
iTrader: (0)
technoguy is on a distinguished road
Default

Why dont you try to give same color for visited link as your hyperlink. So that visited link and non-visited link will be same and then add mouse hover effect to your link.
Reply With Quote
  #8 (permalink)  
Old 03-23-2007, 07:59 AM
creek23 creek23 is offline
WMG Deputy Sheriff
 
Join Date: Mar 2007
Posts: 290
iTrader: (0)
creek23 is on a distinguished road
Default

Quote:
Originally Posted by technoguy View Post
Why dont you try to give same color for visited link as your hyperlink. So that visited link and non-visited link will be same...
I kind of not agree with that solution. Giving a different color on visited links gives the user a hint what he already visited and what he haven't yet. the hover thing is for the design but the visited thing is for *functionality*
Reply With Quote
Reply


Thread Tools
Display Modes

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
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

All times are GMT. The time now is 11:13 PM.



Freelance Web Designers
Work At Home Forum
Ad Marketplace
Online Deals and Bargains
midPhase Web Hosting - $7.95/month - 500 GB B/W! Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.0.0