Answers for "css starts with selector"

CSS
1

css selector starts with

The following should do the trick:

div[class^='myclass'], div[class*=' myclass']{
    color: #F00;
}
Edit: Added wildcard (*) as suggested by David
Posted by: Guest on March-20-2021

Browse Popular Code Answers by Language