The order of link pseudo-classes matters
Common knowledge to most who have been working with CSS for a few years, but perhaps not something that relative newcomers have come across yet: the order in which you define the different link states affects the end result.
I prefer the following order: :link, :visited, :hover, :focus, :active.
Eric Meyer explains why the order matters and why he also prefers defining the states in this order in Link Specificity, Ordering the Link States, and Who Ordered the Link States?.
- Previous post: Dyslexia and accessibility
- Next post: Dissecting the Web with Opera’s MAMA
Comments are disabled for this post (read why), but if you have spotted an error or have additional info that you think should be in this post, feel free to contact me.
Subscribe / follow
Sponsors
Authentic Jobs
- Designer at Saltwater (Portsmouth, NH, Ne, US)
- Software Engineer at Avant Credit (Chicago, IL, Il, US)
- Web Developer PHP/MySQL at eMeals (Atlanta, Ga, Acworth, GA, or Birmingham, AL, Ge, US)
- Data Visualization Graphic Designer at Ultimate Fighting Championship (UFC) (Las Vegas, Ne, US)
DreamHost web hosting
Use the promo code 456BEREASTREET3 to save USD 20 when you sign up for DreamHost

