How to pass value from parent to child window field. I use window.open("www.google.com");
after popwindow is opened i need to pass/set search value typed in parent window to child window(www.google.com)
How to pass value from parent to child window field. I use window.open("www.google.com");
after popwindow is opened i need to pass/set search value typed in parent window to child window(www.google.com)
Set a reference using the window.open() method:
var childWin = window.open("www.google.com" <etc.>);
Then treat childWin as a whole other window. For example,
childWin.document.getElementById('searchField')
will give you a reference to an element with ID of "searchField". Etc. Rinse and repeat.