简体   繁体   English

如何在移动设备而非移动视图中查看整个网站

[英]How to view full site in mobile devices instead of mobile view

When viewing my site on mobile device, the site is automatically viewed in mobile version, like the image i have attached below 在移动设备上查看我的网站时,该网站会自动以移动版本查看,就像我在下面附加的图片一样

我的网站

But i need to view it in desktop view like the image below. 但是我需要在桌面视图中查看它,如下图所示。

网站我的客户

In other words, how to disable mobile view when the site is viewed in mobile device and use the desktop view instead? 换句话说,当在移动设备中查看网站时如何禁用移动视图并改为使用桌面视图?

It's hard to tell with the information given, but perhaps you're using the meta viewport tag: 很难通过给出的信息来判断,但是也许您正在使用meta viewport标签:

<meta name="viewport" content="width=device-width">

If you have something like that in your code, remove it. 如果您的代码中有类似内容,请将其删除。 If your website isn't designed to be responsive, then adding in the meta viewport tag will awkwardly zoom users in. 如果您的网站并非旨在响应时,那么在meta视口标签中添加将使用户放大变得笨拙。

If you don't want your side responsive, you can manually set a width for the viewport. 如果您不希望侧面响应,则可以手动设置视口的宽度。 Add a meta tag like this into your html: 将这样的元标记添加到您的html中:

<meta name="viewport" content="width=1024">

where 1024 should be a width that your site looks good. 其中1024应该是您的网站看起来不错的宽度。 With this number, you can fine tune the appearance of your site. 使用此数字,您可以微调站点的外观。

Also remember to remove any other viewport definitions(especially any width=device-width ). 还要记住删除所有其他视口定义(尤其是width=device-width )。

You may have a look at this article: http://webdesignerwall.com/tutorials/viewport-meta-tag-for-non-responsive-design . 您可以看一下这篇文章: http : //webdesignerwall.com/tutorials/viewport-meta-tag-for-non-sensitive-design

如果您只是想在台式机模式/整个站点上进行测试(对我而言就是这样),并且不想永久禁用移动视图,那么许多浏览器都支持桌面视图:Android Chrome->点击右上角三个点,选择“请求桌面站点”。

If you are using this metadata ,just remove it and the site won't be responsive 如果您正在使用此metadata ,只需将其删除,该网站将不会响应

<meta name="viewport" content="width=device-width">

otherwise you can add metadata for setting your viewport size : 否则,您可以添加metadata来设置viewport大小:

<meta name="viewport" content="width=your-size-in-number">

You may want to read Responsive Web Design - The Viewport 您可能需要阅读自适应网页设计-视口

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM