5

I have tried to achieve this in several ways, none of them work:

<a href="url" target="_blank"/>

<a href="javascript:void(0)" onclick="window.open(url)"/>

<a href="javascript:void(0)" onclick="window.open(url,'_blank')"/>

<a href="javascript:void(0)" onclick="window.open(url,'_newtab')"/>

<a href="javascript:void(0)" onclick="window.open(url,'popup','width=640,height=480')"/>

I read here that this is not possible to control programmatically on Windows Phone 7, however I need a solution for Windows Phone 8.

halfer
  • 19,824
  • 17
  • 99
  • 186
最白目
  • 3,505
  • 6
  • 59
  • 114

2 Answers2

1

There are some minor differences between Internet Explorer 10 for Windows 8 and Internet Explorer 10 for Windows Phone that you need to be aware of. Internet Explorer 10 for Windows Phone does not support the following:

  • Cross-tab communication via script (as a result window.open opens the destination URL in the same tab)
  • Also in Internet Explorer 10 for Windows Phone, Window.open does not return a valid window object. This is because on the phone each “window” is isolated in its own sandbox.

Quote from http://blogs.windows.com/windows_phone/b/wpdev/archive/2012/11/08/internet-explorer-10-brings-html5-to-windows-phone-8-in-a-big-way.aspx - open the link for the full list.

tlk
  • 71
  • 3
  • 8
0

While trying to find an answer to this I stumbled across a question that was already answered here on StackExchange. I own a Windows Phone and am a little saddened at the answer.

How to open a new window or tab via javascript in windows phone 7 browser

NOTE: I realize the question was on Windows Phone 8 and the answer is referring to Windows Phone 7, but I believe the answer is the same.

Community
  • 1
  • 1
BrendonKoz
  • 463
  • 1
  • 6
  • 18