I want to apply same style to
a, a:hover
of elements residing inside an id, class and element. What’s the most valid and effective syntax?
Example:
#leftmenu .shortcuts ul li a, a:hover {
text-decoration: none;
}
Regards,
//t
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.
CSS isn’t that smart, so you’ll have to explicitly write out that first part, again. As
@sdleihssirhcnoted, you can omitli, asulelements are assumed to already containlis, so the selector would still work:I’d consider giving that
ulanid, as it would condense your CSS considerably: