css - Media query to turn site into mobile site -


i've been looking @ few websites, in order construct own websites, , i've noticed when zoom in past percentage, website emulates mobile display. no horizontal scrollbar appears, , fits onto page, , page length increases.

here few example websites - https://generalassemb.ly/, http://learnlayout.com/, http://dev.opera.com/

i'm not sure how implement design, , have searched web explanation.

if possible, walk me through example css?

thanks

this has nothing zoom, current width of window, ( @ least in examples, same happens when change browser's window smaller size ) using css media queries apply conditional styles depending on width.

sample ( first google result http://css-tricks.com/css-media-queries/ )

@media , (max-width: 699px) , (min-width: 520px), (min-width: 1151px) {   body {     background: #ccc;   } } 

Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -