I am trying to select option and redirect page with form action post method to get some information and get back to previous page with those input value after submit by javascript. Could anyone tell me how to do that?
this is my code in js:
var elements = document.getElementsByName("shipping_id")[0];
elements.onchange = function(){
if(this.selectedIndex == 1){
var newWin = open('/test/static/src/html/test.htm','test','height=589,width=1004');
}; };
code in html:
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>test</title>
</head>
<body>
<form method="post" action="http://test.ashx">
<input type="submit" value="submit" />
</form>
</body>
</html>
Thanks and looking forward to hear answers!!