in JS, Window.opener is just a reference to the pop-up window's parent window. This article is mainly on the use of JS opener in detail, the need for friends can come to the reference, I hope to help you.
In JS, Window.opener is just a reference to the pop-up window's parent window. For example: a.html, by clicking the button and so on to window.open out a new window b.html. Then in b.html, we can use Window.opener (omit write as opener) to reference a.html, including a.html document and other objects, manipulate a.html content. If this reference fails, then NULL is returned. Therefore, before calling the opener object, you must first determine whether the object is null, otherwise the "object is empty or does not exist" JS error. Example opener.html code as follows: <html> <body> <form name=form1> <input type=text Name=inpu & Gt <input Type=button onclick= "Javascript:window.open (' Back2opener.html?toname=opener.form1.inpu ');" > </form> </body> </html> back2opener.html code is as follows: <html> <body> <form name= form1> <input type=text name=inpu > <a class=under href=# onclick= "{Opener.document.form1.inpu.value + = ' Sun Chao, ';} ' > Add </a> </form> </body> </html> JS code: window.open (); and when payment is successful, Need to close payment platform payment successful interface, and client load client to pay Success page, JS code: window.opener.location.href=url;window.close ();