First create a parent page
<!doctype html>
<meta http-equiv= "Content-type" content= "text/html; Charset=utf-8 "/>
<title> Parent Page </title>
<script>
function Tanchu () {
window.open ("son.html", "Ziyemian", "Width=300,height=400,top=200,left=300,toobar=no,menubar=no,scrollbars=no, Location=no,status=no ");
}
function ReTurn () {
return document.getElementById ("AAA");
}
</script>
<body>
<input value= "commit" id = "button" type= "button" onclick= "Tanchu ()"/>
<input type= "text" id= "BBB" >
<input type= "text" id= "ddd" value= "123456" >
</body>
Son.html
<!doctype html>
<meta http-equiv= "Content-type" content= "Text/html;charset=utf-8" >
<title> Sub-pages </title>
<body>
<script>
function aaa () {
Window.opener.document.getElementById ("BBB"). value= "123123123";//Pass value to Parent page
Gets the value of the parent page
WINDOW.OPENER.A (); Methods for calling parent pages
Alert (WINDOW.OPENER.A (). value);
}
</script>
<input type= "button" id= "button" value= "Submit" onclick= "aaa ()" >
</body>
window.open Popup Parent page and child page value interaction in Web page