html网页页面相互之间传值的难题处理计划方案

第1次应用随笔,觉得還是蛮别扭的
a.html

拷贝编码
编码以下:

<html>
<head>
<title> demo </title>
<meta name="Author" content="xugang" />
</head>
<body>
<FORM name="frm" METHOD="get" ACTION="b.html" onsubmit="return foo()">
<INPUT TYPE="hidden" id="hid" value="123" name="hid">
<INPUT TYPE="submit" value="递交">
</FORM>
</body>
</html>

b.html

拷贝编码
编码以下:

<HTML>
<HEAD>
<TITLE> New Document </TITLE>
</HEAD>
<BODY>
<SCRIPT LANGUAGE="JavaScript">
document.write(location+"
");
document.write(location.search+"
");
document.write(decodeURIComponent(location.search.substr(location.search.indexOf("=")+1)));
</SCRIPT>
</BODY>
</HTML>