Chrome for IOS不能在iframe中正确打开新窗口 [英] Chrome for IOS not opening new window correctly in iframe

查看:152
本文介绍了Chrome for IOS不能在iframe中正确打开新窗口的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在iframe中的iOS版Chrome中的新窗口中打开链接,但Chrome for iOS不会在新窗口中打开链接,而是浏览器在相同窗口中打开链接,而不是在一个新窗口。弹出窗口也是一样。很奇怪。
$ b 示例:

test.html



 < iframe src =iframe.htmlwidth =500height =250>< / iframe> 



iframe.html



 < SCRIPT type =text / javascript> 
函数open_popup()
{
window.open('http://www.google.com','_blank','');
}
< / SCRIPT>

< a href =http://www.google.comtarget =_ blank>新窗口< / a>< br>
< a href =#onclick =open_popup();>新弹出窗口< / a>

当直接浏览iframe.html时,链接将在新窗口中打开,但在浏览测试时不会打开。 html



这是否是专门设计的,还是iOS版Chrome中的错误?
如果是bug,是否有人知道如何报告这个bug?


(Safari for iOS在浏览测试时打开新窗口中的链接。 html)

解决方案

与其提交此错误(再次),最好为现有问题投票: https://code.google.com/p/chromium/issues/detail?id=135498


I'm trying to open a link in a new window in Chrome for iOS inside an iframe but Chrome for iOS doesn't open the link in a new window, instead the browser opens the link in the same window and not in a new window. The same for popups. Very strange.

Example:

test.html

<iframe src="iframe.html" width="500" height="250"></iframe>

iframe.html

<SCRIPT type="text/javascript">
function open_popup()
{
    window.open('http://www.google.com', '_blank', '');
}
</SCRIPT>

<a href="http://www.google.com" target="_blank">New window</a><br>
<a href="#" onclick="open_popup();">New popup</a>

The links opens in a new window when browsing directly to iframe.html but not when browsing to test.html

Is this by design or is it a bug in Chrome for iOS? If it is a bug, does anyone know how to report this bug?

(Safari for iOS opens the links in a new window when browsing to test.html)

解决方案

Instead of filing this bug (again), it is better to vote for the existing issue: https://code.google.com/p/chromium/issues/detail?id=135498

这篇关于Chrome for IOS不能在iframe中正确打开新窗口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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