##############javascript.html里的内容:
<html>
<head>
<title></title>
<script language="javascript">
function go_back()
{
parent.history.back();
}
function go_forward()
{
parent.history.forward();
}
</script>
</head>
<body>
<input type="button" value="Back" onclick="go_back();">
<input type="button" value="Forward" onclick="go_forward();">
</body>
</html>
<html>
<head>
<title></title>
<script language="javascript">
function go_back()
{
parent.history.back();
}
function go_forward()
{
parent.history.forward();
}
</script>
</head>
<body>
<input type="button" value="Back" onclick="go_back();">
<input type="button" value="Forward" onclick="go_forward();">
</body>
</html>
还有一个问题:
为什么不能用在第二个框架中操作第一个框架的前进和后退??通过使用frames[0]的方式引用第一个框架???
我不明白为什么使用
parent.frames[0].history.back()
错在哪里???
谢谢……
parent.frames[0]就是frames对象了。