javascript - post form input to an iframe on onchange of a select -


using html, css , js, have form containing select , submit - works great.

however, want when select's onchange triggered, option posted page, inside iframe.

meaning when option 'red' selected in 'color' dropdown, i'll able display in iframe /changed?color=red, using post.

however original form has action target can't through simple submit. should do?

use "onsubmit" on form

<script> function myfunction(){   // open iframe } </script>  <form onsubmit="myfunction()" action="...">   enter name: <input type="text">   <input type="submit"> </form> 

Comments

Popular posts from this blog

ios - RestKit 0.20 — CoreData: error: Failed to call designated initializer on NSManagedObject class (again) -

java - Digest auth with Spring Security using javaconfig -

laravel - PDOException in Connector.php line 55: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: YES) -