CSS responsive design - detect portrait display -


i know it's pure css possible adapt stylesheet according screen dimensions, this:

@media (max-width: 959px) {   /* styles smallest viewport widths */ }  @media (min-width: 600px) , (max-width: 959px) {   /* styles mid-tier viewport widths */ }  @media (min-width: 960px) {   /* original css styles */ } 

(source)

is pure css possible check on landscape or portrait display?

yes, using following syntax:

@media , (orientation: landscape) {} 

see w3 specs more information.


Comments

Popular posts from this blog

Winapi c++: DialogBox hangs when breaking a loop -

vb.net - Font adding using PDFsharp -

javascript - jQuery iScroll clickable list elements while retaining scroll? -