Media query Help?

HTML, CSS and anything else that deals with client side capabilities.

Moderator: General Moderators

Post Reply
Forum Commoner
Posts: 33
Joined: Fri Oct 10, 2014 2:30 am

Media query Help?

Post by Darrel »

I am trying to get my website to be responsive and I am testing it on the Ipad2 yet I can not get it to be responsive.

On my HTML and I added the meta name...

<meta name="viewport" content="width=device-width, initial-scale=1.0">

{background-color: red}

and in the CSS I have added the query...

@media only screen
and (min-device-width : 768px)
and (max-device-width : 1024px)

{background-color: blue;}

So In theory, the ipad should display my background as blue which it does but so does my desktop. Why is my desktop (screensize 1280 x 800) change to background-color blue?

User avatar
Posts: 6425
Joined: Tue Nov 09, 2010 2:39 pm
Location: Montreal, Canada

Re: Media query Help?

Post by Celauran »

Works fine for me. To what selector are you applying the red background?
Post Reply