收藏 求大神指导怎么使【手机浏览器】输入【www网址】自动跳转【手机版】页面!

WBOY
Release: 2016-06-13 12:52:58
Original
3096 people have browsed it

收藏 求大神指导如何使【手机浏览器】输入【www网址】自动跳转【手机版】页面!!
求了解如何使手机浏览器输入www网址自动跳转手机版页面

比如说,手机浏览器输入www.sina.com.cn,浏览器会自动跳入3g.sina.com.cn,求指导求源代码,在线等!!


------解决方案--------------------
判断客户端agent
判断ISP
判断客户端能支持某些手机的特性(通过js之类)
……

但可以告诉你上述没有一个是精确的,最好还是做个按钮让客户选择

BTW:前两年有段时间,我用x64 的 firefox(PC) 访问新浪首页,总是自动跳转到wap版,还没返回的设置,让我觉得新浪很垃圾,大概一个月后才修正……
------解决方案--------------------
还是做多个让用户选择的功能吧!!默认是PC版!!判断浏览器标识也是个不错的方法!!
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template