Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML

Page works when I shrink the page down to mobile size on my desktop but not if I upload it on my phone.

I just made a website and one page the ebook page (http://www.tvisionfitness.com/ebooks.html#close) works as it is supposed to on the desktop. It shrinks down to mobile size when checking it on the desktop but when I check it on my phone it has trouble loading and it will only load the desktop version not the mobile version. All the other pages works fine when checking it on my phone. I understand it is useful if I post the code, there is just a lot of it and I do not know the problem area so I cant just post the part of the code I have the problem with. Does anyone know what causes the media queries to work on the desktop but not when checking it out on a phone? Thanks in advance

2 Answers

Hey John,

Looks to me like that page that's working is the only one that contains a meta tag to define the width.

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

That's the tag you're looking for. Make sure it's between the <head> tags.

Good luck!

Thanks, that solved my problem. Thanks again.