Can one of you CSS experts explain this designator (if that\'s even what you\'d call it) to me? I understand the contents, just not the a.button.gold. Two dots?
<
The selector simply means select any a
element having class .button
AS WELL AS .gold
so your anchor tag should look like
Hello
Demo
The selector can be also written as element[attr~=val]
as @BoltClock Commented like
a[class~="button"][class~="gold"] {
color: #f00;
}
Demo
Generally the above(Not the selector, but calling multiple classes for a single element method) is also used when you want to apply properties of 2 classes to a single element, so say for example you have .demo
having color: green;
and .demo2
having font-weight: bold;
so using
Hello, this will be green as well as bold
Will make it green as well as bold. Demo 2