响应式网站在手机上以全宽显示(但不在模拟手机上)

时间:2014-09-18 16:56:28

标签: css mobile responsive-design

这是一个回应主题:http://bsetec.com/demoprojects/magento/free_templates/index.php/?___store=electronics_english

如果您在模拟的移动浏览器中查看该网站,则会显示窄版本(这是所需的行为)。 http://transmog.net/iphone-simulator/mobile-web-browser-emulator.php?u=http://bsetec.com/demoprojects/magento/free_templates/index.php/?___store=electronics_english

但如果我在实际的移动设备上查看它,我会看到桌面版。

我需要更改哪些内容才能看到手机上的窄版布局?bad on real phone and good on emulated phone

1 个答案:

答案 0 :(得分:2)

添加

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

到你的页面的头部,我认为这是你的麻烦的来源。

如果没有这个,智能手机通常会缩放页面以适应,这不是您想要的响应式网站。

祝你好运!

相关问题