我正在实施社交身份验证。当用户单击按钮时,我发送一条命令,以便我可以调用window.open()
.
Looking at this call-stack, we can see that the port handler is called in the next event loop:
Since window.open
没有在点击事件生命周期内被调用,像 safari 这样的浏览器不允许弹出窗口显示。
你的方法是什么?
它不是超级漂亮,但你可以做类似的事情
a
[ Html.Attributes.attribute "onClick" "window.open(this.href, this.target, 'width=800,height=600'); return false;" ]
[ text "Click me" ]
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)