refresh the frame above automatically

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
Sevengraff
Forum Contributor
Posts: 232
Joined: Thu Apr 25, 2002 9:34 pm
Location: California USA
Contact:

refresh the frame above automatically

Post by Sevengraff »

Im not sure how to do this, but in my frame page...

<HTML>
<FRAMESET ROWS="80%,20%">
<FRAME SRC="one.html">
<FRAME SRC="two.html">
</FRAMESET>
</HTML>

what do i put in two.html so that one.html gets refreshed when one.html is loaded?
User avatar
haagen
Forum Commoner
Posts: 79
Joined: Thu Jul 11, 2002 3:57 pm
Location: Sweden, Lund

Post by haagen »

This is how I would do it.

First give the frames names; one and two.

Then in to you'll write a small script.

Code: Select all

<script language="JavaScript">
<!--
function reloadone()&#123;
  parent.one.document.location.href = "one.html";
&#125;
-->
</script>
<body onLoad="reloadone()">
I haven't tested the code above, but I have used the idea sometimes and it works well.

Good luck!
Post Reply