<form id="" name="" onsubmit="return a_js_func();" action="">
<input type="radio" name="name1" / onclick="form.action='***1'">
<input type="radio" name="name2" / onclick="form.action='***2'">

解决方案 »

  1.   

    如果是这样呢,即默认是选中一个的,如下这样写对不对呢
    <form id="" name="form1" onsubmit="return a_js_func();" action="***1" method="post">
    <input type="radio" name="name1" checked />
    <input type="radio" name="name2" / onclick="form1.action='***2'">
      

  2.   

    <form id="" name="form1" onsubmit="return a_js_func();" action="***1" method="post">
    <input type="radio" name="name" checked />
    <input type="radio" name="name" / onclick="form1.action='***2'">
      

  3.   

    <form id="" name="form1" onsubmit="return a_js_func();" action="***1" method="post">
    <input type="radio" name="name1" onclick="form.action='***1'" checked />
    <input type="radio" name="name2" onclick="form1.action='***2'">
      

  4.   

    楼上的name1.onclick事件里面form1写成了form,其它部分正解
      

  5.   

    <form name="form1" id="" onsubmit="return a_js_func();" target="_blank" action="***1" method="post">
    <input type="radio" name="sth" checked />
    <input type="radio" name="sth" / onclick="form1.action='***2'" />现在登陆的页面在新窗口打开,如何能在打开新窗口后,原窗口中的密码输入框中自动清空呢,即那些代表密码的字符也就没了?
      

  6.   

    楼上的name1.onclick事件里面form1写成了form,其它部分正解
    ----------------------------
    hehe :)
    现在登陆的页面在新窗口打开,如何能在打开新窗口后,原窗口中的密码输入框中自动清空呢,即那些代表密码的字符也就没了?
    ---------------------------------
    <form name="myForm" action="login.php" target="_blank" method="post">
    ...
    <input type="password" name="pwd">
    <input type="button" value="Submit" onClick="submitForm();">
    ...
    </form>
    <script>
    function submitForm(){
    document.getElementByName("pwd").value="";
    myForm.submit();
    }
    </script>
      

  7.   

    sorry,the codes above is wrong.
    the right one:
    <form name="myForm" action="login.php" target="_blank" method="post">
    ...
    <input type="password" name="pwd">
    <input type="button" value="Submit" onClick="submitForm();">
    ...
    </form>
    <script>
    function submitForm(){
    myForm.submit();
    document.getElementByName("pwd").value="";
    }
    </script>
      

  8.   

    谢谢zeroleonhart(没有螺母的螺丝钉)!
      

  9.   

    <form name="myForm" action="" target="_blank" method="post">
    ...
    <input type="password" name="password" />
    <input type="image" src="" onclick="submitForm()" />
    ...
    </form>
    <script type="text/javascript">
    function submitForm()
    {
    myForm.submit(); //我把这句去了,因为会出现两个新的登陆窗口
    document.getElementByName("password").value = "";
    }
    </script>
    这样不行呢