简体   繁体   English

在Windows 8中将用户重定向到桌面浏览器

[英]Redirect user to desktop browser in windows 8

Is there a way to force or prompt a user to use the windows 8 desktop browser if they hit my web page with the windows 8 RT browser? 如果用户使用Windows 8 RT浏览器访问我的网页,是否可以强迫或提示用户使用Windows 8桌面浏览器? I want to be able to use plugins like Silverlight. 我希望能够使用Silverlight等插件。

Yes, you can prompt users to switch to the Desktop version. 是的,您可以提示用户切换到桌面版本。 Microsoft added this as a fallback for sites that need it. Microsoft将此添加为需要它的站点的后备。 (But not with JavaScript) (但不适用于JavaScript)

http://blogs.msdn.com/b/ie/archive/2012/01/31/web-sites-and-a-plug-in-free-web.aspx http://blogs.msdn.com/b/ie/archive/2012/01/31/web-sites-and-a-plug-in-free-web.aspx

Developers with sites that need plug-ins can use an HTTP header or meta tag to signal Metro style Internet Explorer to prompt the user. 具有需要插件的站点的开发人员可以使用HTTP标头或meta标记来表示Metro风格的Internet Explorer提示用户。

HTTP Header HTTP头

X-UA-Compatible: requiresActiveX=true

META Tag META标签

<meta http-equiv="X-UA-Compatible" content="requiresActiveX=true" />

Metro style IE10 detects these flags, and provides the consumer a one-touch option to switch to IE10 on the desktop: Metro风格的IE10会检测到这些标志,并为用户提供一键式选项以在桌面上切换到IE10:

Microsoft is strongly encouraging us, however, to move to an HTM5 plug-in free world. 但是,Microsoft强烈鼓励我们过渡到HTM5插件免费的世界。 Whether that happens or not remains to be seen, but it wouldn't surprise me if they made it harder and harder to use plug-ins in the future. 是否发生这种情况还有待观察,但是如果将来它们变得越来越难使用插件,这也不会令我感到惊讶。 They're the source of plenty of security holes. 它们是大量安全漏洞的来源。

So long-term, it might be better to start eliminating the use of plug-ins in your code. 从长期来看,最好不要在代码中使用插件。 That makes sense considering the plethora of Android, IOS, and other tablets and phones out there. 考虑到大量的Android,IOS以及其他平板电脑和手机,这是有道理的。 Cross-platform web development has never been more important than it is now, and I'm betting that will continue to be the trend. 跨平台的Web开发从未像现在这样重要,我敢打赌这将继续成为趋势。

If you design your website so that it is limited to be used in one browser, people might just avoid using it altogether. 如果您将网站设计为仅限于在一种浏览器中使用,则人们可能会完全避免使用它。 I know I would, unless it was a website that I HAD to use. 我知道我会的,除非这是我必须使用的网站。 ie banking website, or something for work. 即银行网站或一些工作场所。

Perhaps you should make a cross browser friendly website, and for the more enhanced features create an APP? 也许您应该创建一个跨浏览器友好的网站,并为更增强的功能创建一个APP?

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

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