gudii9
asked on
CSS links
Hi,
I read as
When setting the style for several link states, there are some order rules:
a:hover MUST come after a:link and a:visited
a:active MUST come after a:hover
I have not understood
>>>>a:hover MUST come after a:link and a:visited
why a:hover has to come after a:visited esp when user first time visits link he need not have visited link earlier right. Please advise. Any links resources, sample code, ideas highly appreciuated thanks in advance
I read as
When setting the style for several link states, there are some order rules:
a:hover MUST come after a:link and a:visited
a:active MUST come after a:hover
I have not understood
>>>>a:hover MUST come after a:link and a:visited
why a:hover has to come after a:visited esp when user first time visits link he need not have visited link earlier right. Please advise. Any links resources, sample code, ideas highly appreciuated thanks in advance
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
The order is important because of the "cascading" thing. The last declared rule overrides the ones declared before it. So they need to be in Link, Visited, Hover, Active sequence for them to be applied correctly by the browser.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Please grant the points and close the question, thanks :-)
To be clear here: I'm not asking for grant the points to me, but generally.
If you have a problem with any suggestion from experts or nothing works with your expectation, please let us know, so we will continue work on solution for you, thanks.
If you have a problem with any suggestion from experts or nothing works with your expectation, please let us know, so we will continue work on solution for you, thanks.
ASKER
>>>> The last declared rule overrides the ones declared before it.
Last declared means the recently declared one. How we know which one has to be declared last. So the link miust be last one declared (after Visited, Hover, Active sequence). please advise
Last declared means the recently declared one. How we know which one has to be declared last. So the link miust be last one declared (after Visited, Hover, Active sequence). please advise
ASKER
>>>>It is not related to how/when a user actually uses the link.
it is not related with usage but still the order of declaration is important? why is it so. please advise