怎样获取中文本框的值并把它保存为一个变量
<html>
<title>实时输入显示</title>
<head>
<script language="javascript">
function TxtA_Change(val)
{
var DispDiv=document.getElementById("ShowInp");
DispDiv.innerHTML=val;
}
</script>
</head>
<body>
<input type="text" name="ass" onChange="TxtA_Change(this.value);" size="30" >
<table border="2" width="12%" id="table1" cellspacing="0" cellpadding="0" bordercolor="#000000">
<tr>
<td>
<div id="ShowInp"></div>
</td>
</tr>
</table>
</body>
</html>