复制代码 代码如下:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE> New Document </TITLE>
<META NAME="Generator" CONTENT="EditPlus">
<META NAME="Author" CONTENT="">
<META NAME="Keywords" CONTENT="">
<META NAME="Description" CONTENT="">
<SCRIPT LANGUAGE="JavaScript">
<!--
function setfocus()
{
txt.focus();
// 或者
// document.getElementById("txt").focus();
}
//-->
</SCRIPT>
</HEAD>
<BODY onload="setfocus()">
<INPUT TYPE="text" NAME="txt">
</BODY>
</HTML>