即使脚本在

编程入门 行业动态 更新时间:2024-10-11 17:28:31
本文介绍了即使脚本在_blank窗口中运行,我们也可以在原始窗口上触发脚本吗的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

这是设置:

在Paypal上单击按钮(在_blank中打开),我的焦点窗口变为Paypal,可以在原始窗口中运行脚本.

On Paypal click button (openned in _blank) My focus window becomes Paypal, is it possible to run a script in original window.

现在我的脚本是((如果目标位于原始页面的iframe中,效果很好),但是Paypal不允许,这就是我遇到的问题的原因)

Right now my script is (and it works well if target is within iframe of original page - but Paypal does do not allow it, that's why I have the issue):

$click = '<script type="text/javascript">window.top.parent.parent.submitsubmit();</script>'; echo $click;

只是想知道我想做的事是否现实,

Just wondering if what I want to do is realistic,

预先感谢

推荐答案

可以对已在_blank中打开的窗口进行脚本编写.但是,如果打开的URL具有不同的(子)域,则无法访问内容.

Scripting towards a window that has been opened in a _blank is possible. However accessing the contents is not possible when the opened url is of a different (sub)domain.

更多推荐

即使脚本在

本文发布于:2023-11-23 13:28:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1621613.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:脚本

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!