Please have a look:
http://web.seekware.ch/test/frame
If you press the Next button, frame 1b will be shown but because the input
box is '0' the frameset index.html gets reloaded (because of the
JavaScript). I know this doesn't make really sense. However, in my project I
use an input box in a second frame to verify if everything is fine or if the
frameset (index.html) has to be reloaded again.
If you press several times the Next button Opera doesn't reload the frameset
(index.html) but it does reload all the time frame 1b.
(PS:If you don't experience that problem try to change the value '0' to '1'
and press Next, do a reload on the browser, go back and forward with the
browser buttons, ...)
I guess it's something like a caching problem. However, it's really very bad
because with Opera my pages sometimes gets uninterruptable reloaded.
And here's the code:
--------------------------------------------------
index.html
=======
<html>
<frameset rows = "50%, 50%">
<frame src="frame1a.html" name="MyFrame1">
<frame src="frame2.html" name="MyFrame2">
</frameset>
</html>
--------------------------------------------------
frame1a.html
=========
<html>
<body>
Frame 1a
<input type = "button" value = "Next" onClick = "document.location.href
= 'frame1b.html'">
</body>
</html>
--------------------------------------------------
frame1b.html
=========
<html>
<head>
<script type = "text/javascript">
function FormLoaded() {
if (parent.MyFrame2.document.MyForm2.MyInput2.value == 0) {
parent.location.href = "index.html";
}
}
</script>
</head>
<body onLoad = "FormLoaded()">
Frame 1b
</body>
</html>
--------------------------------------------------
frame2.html
========
<html>
<body>
<form name = "MyForm2" action = "" method = "post">
<input type = "text" name = "MyInput2" value = "0"
</form>
</body>
</html>