...

View Full Version : Update window.name when the frame window is scrolled.



skl
09-27-2005, 07:25 PM
index.htm:

<frameset rows="*,*">
<frame name="topFrame" src=file1.htm scrolling="auto">
<frame name="bottomFrame" src=file2.htm>
</frameset>
----------------------------------------------------------------------
both file1.htm and file2.htm include the "J2Frames.js":

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>

<head>
...
<script type="text/javascript" language="JavaScript" SRC="J2Frames.js">
</script>

</head>

----------------------------------------------------------------------
if (window.name == "TopLeftFrame") {
...
}
else if (window.name == "BottomRightFrame") {
...
}
----------------------------------------------------------------------
The problem I am having is when I click on the vertical scroll bar to scroll the page content up/down, the window.name is not changed to the name
of the active frame that I was scrolling. I have to click inside the frame then it will update the window.name. Is it an easy way of updating the wndow.name when the frame window is scrolled?

Thanks,
skl

rm-f
09-27-2005, 08:54 PM
onscroll event handler



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum