简体   繁体   English

来自移动网站的桌面网站链接

[英]Desktop site link from mobile site

I am working on a site that has a mobile site: http://www.exchequersolutions.co.uk/m/ I am trying to create a link to the desktop site with out much luck. 我正在一个有移动网站的网站上工作: http : //www.exchequersolutions.co.uk/m/我正在尝试创建一个到桌面网站的链接,但运气不佳。

When the user clicks on a link I want them to be taken to the desktop site. 当用户单击链接时,我希望他们被带到桌面站点。

The link in the anchor tag is: 定位标记中的链接为:

    <p><a href="http://www.exchequersolutions.co.uk/contractors/cis-self-employed/cis-form/" target="_blank" class="cis_register" >Register Online</a></p>

Does anybody know how or even if this is possible? 有谁知道这是可能的,甚至是可能的吗?

Is not possible. 不可能。

Every browser implement a function to save a link on OS FileSystem (drag&drop or file > save as ...). 每个浏览器都实现了在OS FileSystem上保存链接的功能(拖放或文件>另存为...)。

You're stuck in a loop caused by user-agent detection. 由于用户代理检测,您陷入了一个循环。

It looks like there is device detection on the desktop site that uses the user-agent to identify mobile devices. 桌面站点上似乎存在使用用户代理标识移动设备的设备检测。 If you follow a link to the desktop site using a mobile phone, you'll just be sent back to the mobile site. 如果您使用手机点击了指向桌面网站的链接,则只会将您发送回该网站。

There are a few different ways you can fix this, but it depends on your site architecture. 您可以通过几种不同的方法来解决此问题,但这取决于您的站点体系结构。 One way would be to disable the redirect on the desktop site if you include a specific parameter in the query string. 一种方法是,如果在查询字符串中包含特定参数,则在桌面站点上禁用重定向。 Another option would be to set a cookie and use that to disable the redirect. 另一种选择是设置一个cookie并使用它来禁用重定向。

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

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