[Solved -6 Answers] CSS – HTML – wildcard * in CSS for classes
We have these divs that styling with .tocolor, but we also need the unique identifier 1,2,3,4 etc. so we are adding that it as another class tocolor-1.
* – will match any part of the attribute value to the given string
^ – will match if the attribute begins with the given string (think class prefixes)
$ – matches if the attribute ends with the given string
Note :in the second selector, there’s an extra whitespace before “mike” which accounts for IE’s handling of having multiple classes (e.g. class=”mikebox mike-1″).
Wikitechy Founder, Author, International Speaker, and Job Consultant. My role as the CEO of Wikitechy, I help businesses build their next generation digital platforms and help with their product innovation and growth strategy. I'm a frequent speaker at tech conferences and events.