Hi,
I have a page named frame .html that defines 2 frames namely upperframe and lowerframe. The code is as follows,
<html>
<frameset rows=”10%,*” frameborder=”1″>
<frame name=”upperframe” src=”left.htm”>
<frame name=”lowerframe” src=”right.htm”>
</frameset>
</html>
The code for left.html is as follows
<html>
<body bgcolor=”#EBC79E”>
<h3>Frame B</h3>
</body>
</html>
The code for right.html is as follows
<html>
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=windows-1252″>
<script type=”text/javascript”>
function changeurl()
{
parent.upperframe.location.href=”demo.htm”
parent.lowerframe.location.href=”right.htm”
}
</script>
</head>
<body>
<form>
<input type=”button” onclick=”changeurl()” value=”Change url” >
</form>
</body>
</html>
The code for demo.html is as follows,
<html>
<body bgcolor=”red”>
<h3>Frame a</h3>
</body>
</html>
When the Change url button is clicked I want the demo.html to be loaded in the upperframe and want the lowerframe to remain as it is. But somehow this does not seem to work. Please help.