JavaScript jQuery Basics (2014) Creating a Mobile Drop Down Menu Perform: Part 3

JORGE HERRANDO GARIJO
JORGE HERRANDO GARIJO
6,479 Points

Why you don't need the $ symbol when you call $select and $button in CSS??

why

@media (min-width: 568px) {
  #menu select, #menu button {
    display:none;
  }
}

instead of:

@media (min-width: 568px) {
  #menu $select, #menu $button {
    display:none;
  }
}

1 Answer

Andrey Misikhin
Andrey Misikhin
14,842 Points

Because it is rule of CSS syntax, it is not php. You get elements by tags, you not create a variable.