Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
May 22, 2013 11:06 pm GMT

Logic in Media Queries

Just in case you have brain farts about this constantly like I do.

If

That's what media queries are: logical if statements. "If" these things are true about the browser, use the CSS inside.

And

The keyword and.

@media (min-width: 600px) and (max-width: 800px) { html { background: red; }}Or

Comma separate.

@media (max-width: 600px), (min-width: 800px) { html { background: red; }}

Technically these are treated like to separate media queries, but that is effectively …


jQuery Conference Portland 2013 has a limited number of regular tickets still available. Two days. Two tracks. Fresh speakers. Jun 13-14. $50 off for members of the jQuery Foundation. Join today and get your first year of fan dues paid for with purchase of both a training and conference ticket. Training provided by Bocoup on Jun 12. Use coupon code CSSTricks25off for $25 off.


Logic in Media Queries is a post from CSS-Tricks


Original Link: http://css-tricks.com/logic-in-media-queries/

Share this article:    Share on Facebook
View Full Article

CSS Tricks

A Web Design Community curated by Chris Coyier

More About this Source Visit CSS Tricks