<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>输入框为只读-www.jb200.com</title>
<script src="/
jquery/1.3.2/jquery.min.js" type="text/
javascript"></script>
<script type="text/javascript">
function setDisabled(bo) {
$("#table1 :input").attr("disabled",bo);
}
</script>
</head>
<body>
<input id="Button1" type="button" value="启用" onclick="setDisabled(false)" />
<input id="Button2" type="button" value="禁用" onclick="setDisabled(true)" />
<table id="table1" >
<tr>
<td>
<input id="Text1" type="text" />
</td>
<td>
<input id="Password1" type="password" />
</td>
</tr>
<tr>
<td>
<select id="Select1">
<option>1</option>
</select>
</td>
<td>
<input id="
checkbox1" type="checkbox" />
<input id="Radio1" type="radio" />
</td>
</tr>
<tr>
<td>
<input id="File1" type="file" />
</td>
<td>
<textarea id="TextArea1" cols="20" rows="2"></textarea>
</td>
</tr>
</table>
</body>
</html>