我在子文件夹/子文件夹中有 PHP 页面。在根目录中,我有两个文件:index.html 和 demo.html。
演示.html:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf8" />
<meta name="description" content="" />
<meta name="keywords" content="" />
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_jumpMenu(targ,selObj,restore){ //v3.0
eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
if (restore) selObj.selectedIndex=0;
}
//-->
</script>
</head>
<body>
<div id="demo_wrapper">
<div id="themeslist">
<form action="" name="form" id="form">
<select name="select" onChange="MM_jumpMenu('parent',this,1)">
<option value="#">Select Theme</option>
<option value="http://127.0.0.1/themes/index.php?theme=1">Theme1</option>
<option value="http://127.0.0.1/themes/index.php?theme=3">Theme2</option>
</select>
</form>
</div>
</div>
</body>
</html>
和 index.html:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf8" />
<meta name="description" content="" />
<meta name="keywords" content="" />
</head>
<frameset rows="100,*" framespacing="0" frameborder="no" border="0">
<frame src="http://127.0.0.1/demo.html" name="head_frame" scrolling="no" noresize="noresize" id="head_frame" title="head_frame" />
<frame src="http://127.0.0.1/themes/index.php" name="main_iframe" id="main_iframe" title="main_iframe" />
</frameset>
<noframes>
<p>Your browser does not handle frames!</p>
</noframes>
</html>
来源:http ://www.entheosweb.com/website_design/jump_menus.asp
现在的问题是当我在菜单中选择选项时 - 它会重新加载整个页面并且框架消失。仅重新加载选定的框架(main_iframe)有什么变化?