[英]window.open(…) getting blocked in some browsers
I have a script where it opens a window for online application after executing some other scripts.我有一个脚本,它在执行其他一些脚本后打开一个用于在线应用程序的窗口。
window.open()
is not called on any click. window.open()
不会在任何点击时调用。 It is getting called in a script and browser prevents the new window from appearing.它在脚本中被调用,浏览器会阻止新窗口出现。
How to overcome this?如何克服这一点?
Here is the code:这是代码:
window.open('/search/applyonline?jobid=".$jobDetails->getIdjob()."',
'applyurljob',
'height=550,\
width=800,\
toolbar=no,\
directories=no,\
status=no,\
menubar=no,\
scrollbars=yes,\
resizable=yes,\
left=200,\
top=250')
Popup blockers will block windows from being opened that are not in response to a click event.弹出窗口阻止程序将阻止打开未响应单击事件的窗口。 Therefore you can:
因此,您可以:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.