Should you use a:hover, a:active, a:visited and a:link, or similar javascript things (tags??) instead?
Should you use a:hover, a:active, a:visited and a:link, or similar javascript things (tags??) instead?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Highly dependent on what you’re trying to do. If a:active/:visited/:link/:hover provide sufficient styling control, use those as they work across browsers with or without JavaScript enabled. If you’re trying to do something fancy that can’t be accomplished with CSS, then use JavaScript. It’s also common to mix the two techniques… Use CSS for the parts where you can and use JavaScript for everything else.