Brothers, I have a requirement like this: I have a website and access the Web page through www.website.com, but I want to make a corresponding Wap page for the corresponding Web page to simplify and improve the mobile terminal. The user’s experience of visiting this page and adapting the page can then be accessed through m.website.com. We need to give our page URL to our partners in certain scenarios. We hope to redirect www.website.com The link is given to the partner until the user accesses the mobile user based on the client's UA (User-Agent) and rewrites to the page corresponding to m.website.com, so please tell me how to rewrite based on the UA in Apache. ? And how do you distinguish between so many UAs and whether they are mobile (http://www.user-agents.org/)?
What is the Web field without pioneers? Reference: http://detectmobilebrowsers.com/, the first item in alphabetical order, Apache
UA Although this method can also be implemented, UA is often not accurate. There are so many browsers now, and new ones pop up every day, which causes a heavy workload for subsequent maintenance of UA, so it is more recommended to use the method of judging the resolution size. way to achieve it. For example, use javascript to judge
There is also an improvement based on the existing website, which is Media Queries using CSS3
Example reference http://webdesignerwall.com/tutorials/...