Can we use the “>” or “<” symbols(Greater than and Less than ) in media queries? for example I would like to hide a dive for all monitors less than 768px. can I say some thing like this:
@media screen and (min-width<=768px) {}
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Media queries don’t make use of those symbols. Instead, they use the
min-andmax-prefixes. This is covered in the spec:So, instead of something like
(width <= 768px), you would say(max-width: 768px)instead: