如何在Windows Phone 7浏览器中通过JavaScript打开新窗口或标签页 [英] How to open a new window or tab via javascript in windows phone 7 browser

查看:113
本文介绍了如何在Windows Phone 7浏览器中通过JavaScript打开新窗口或标签页的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以在Windows Phone 7浏览器中通过javascript打开新窗口或标签页?

Is it possible to open a new window or tab via javascript in Windows Phone 7 browser?

window.open似乎不受支持,target='_blank'也不受支持.

window.open does not appear to be supported nor does target='_blank'.

我在这里错过了什么吗?此基本功能在iPhone和Android上正常运行. 关于如何使它在Windows Phone 7中正常运行的任何想法?

Am I missing something here? This basic feature works just fine on iphone and android. Any ideas on how I can get this working in Windows Phone 7?

推荐答案

在Windows Phone 7上,这无法通过编程实现.全部掌握在用户手中.

On Windows Phone 7 this is not possible programmatically. It's all in the users hand.

要引用 Microsoft员工:

用户可以通过以下方式打开新标签页中的链接: 获取上下文菜单,但锚点或脚本请求以新目标为目标 窗口将被忽略.

"A user can open a link in a new Tab by tapping and holding the link to get the context menu but an anchor or scripts request to target a new window is ignored.

有几个原因:

  • 不支持跨窗口通信.
  • Windows Phone只有一个实例 浏览器如此新的窗口"必须以Tab的形式打开.
  • 浏览器体验是全屏的,因此用户没有很好的视觉提示, 除非明确要求,否则将移至新的标签.
  • 导航返回"在新标签页中退出浏览器 如果他们不知道是否创建了新的标签,则会使用户感到困惑."
  • Cross-window communications are not supported.
  • Windows Phone only has one instance of the browser so new "windows" have to be opened as Tab's.
  • The browser experience is full screen so the user has no good visual cue that they have moved to a new Tab unless they explicity request it.
  • Navigating "back" in a new Tab exits the browser which would be confusing to the user if they did not know a new Tab was created."

这篇关于如何在Windows Phone 7浏览器中通过JavaScript打开新窗口或标签页的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆