1.你的js代码引用了source这个窗体,js代码之前还没有这个form呀,你要写在后面
2.Words = document.source.s.value 这句呢一开始就取得s的值,可这时没有值,
我不知你到底要干什么。如果只是除错误,下面这样就可以啦:
<HTML>
<BODY>
<form name=source>
<input type=text name=s size=90>
<input type=button onclick="password()" value="解密">
</form>
<form name=pw>
<textarea name="txtpw" cols="100" rows="25"></textarea>
</form>
</BODY>
<SCRIPT LANGUAGE="JavaScript">
var Words = document.source.s.value;
var NewWords;
NewWords = unescape(Words);
NewWords=NewWords.toString();
function password(){
document.pw.txtpw.value=NewWords;
}
</SCRIPT>
</HTML>