我有一個表格奠定了這樣的:啓用/禁用基於單選按鈕提交按鈕
<form action="join-head-2-head.php" method="POST" enctype="application/x-www-form-urlencoded">
<table border="0" cellspacing="4" cellpadding="4">
<tr>
<td colspan="2"><input name="player1rules" type="radio" id="tandcy" value="y" />
<label for="tandcy">I Have Reviewed The Rules And The Terms & Conditions And Agree To Abide By Them</label></td>
</tr>
<tr>
<td colspan="2"><input name="player1rules" type="radio" id="tandcn" value="n" checked="checked" /><label for="tandcn">I Do Not Agree To The Terms And Condtions And/Or Have Not Read The Rules</label></td>
</tr>
<tr>
<td width="100"><input name="player1" type="hidden" value="<? $session->username; ?>" /></td>
<td><input type="submit" name="join" id="join" value="Take Available Slot" /></td>
</tr>
</table>
</form>
我所希望做的是禁用的提交按鈕,如果ID =「tandcn」被選中,並啓用當id =「tandcy」時。有沒有簡單的方法來做到這一點使用JavaScript?
你使用jquery? – Karthik 2011-04-28 12:17:52