Question: what is the difference between a selector and an attribute?
Answer: 3 Answers. The former is used to select elements that contain a whole specific word. The latter is used to select any string containment, it doesn't have to be a whole word. The ~= is called Attribute Contains Word Selector.