PHP : how to trigger javascript function from a button in another page -


enter image description here

i have 3 buttons.

  1. search button : open popup page.
  2. add row button : trigger javascript function add row.
  3. select button : trigger javascript function row value , send main page.

search , add row buttons in main page, , select button on popup page.

i need select button handle javascript function in main page, can remove add row button.

to put simple, question how trigger javascript function add row in main page, using select button in popup page?

if question isn't clear please ask, thanks.

i take general example.

(parent window)

<html>  <script language="javascript">  function openwindow() {    window.open("target.html","_blank","height=200,width=400, status=yes,toolbar=no,menubar=no,location=no");  }  </script>  <body>  <form name=frm>  <input id=text1 type=text>  <input type=button onclick="javascript:openwindow()" value="open window..">  </form>  </body>  </html> 

(child window)

<html>  <script language="javascript">  function changeparent() {    window.opener.document.getelementbyid('text1').value="value changed..";   window.close(); }  </script>  <body>  <form>  <input type=button onclick="javascript:changeparent()" value="change opener's textbox's value..">  </form>  </body>  </html> 

http://www.codehappiness.com/post/access-parent-window-from-child-window-or-access-child-window-from-parent-window-using-javascript.aspx

more discussion: javascript - pass selected value popup window parent window input box


Comments

Popular posts from this blog

html - Difficulties with background-image property -

visual studio code - What does the isShellCommand property actually do and how should you use it? -

ios - Segue not passing data between ViewControllers -