method 1:

<form name="form1" method="post" action="../ news/index.asp">
   <table width="100%" height="43" border="0" cellpadding="0" cellspacing="0"&​​gt;
     <td height="28"><input name="keyword" type="text" /></td>
     <td height="28"><select name="searchtype" onchange="searchtype1 ();">
      <option value="news" selected="selected">News</option>
      <option value="case">Engineering Case</option>
     <input type="submit" name="submit" value="search" /></td>
 <script language="javascript">
 function searchtype1 () {
 var type=document.getelementbyid ("searchtype"). options [document.getelementbyid ("searchtype"). selectedindex] .value;
 if (type == "news") {document.getelementbyid ("form1"). action="../ news/index.asp"}
 else if (type == "case") {document.getelementbyid ("form1"). action="../ case/index.asp"}

Method 2:

<script language="javascript">
function check () {
if (document.form1.a [0] .checked == true)
<form name="form1" method="post" action="" onsubmit="check ();">
Go to page one<input type="radio" name="a">
Go to page two<input type="radio" name="a">
<input name="" type="submit" value="submit">
  • Previous Using Ajax technology to achieve partial refresh of the quantity and total price of the sample code
  • Next Angularjs filter usage in detail
  • Trends