I have had a frames based website running for a quite a while in which every page has the following call:
<body onload="top.SetPageTitle()">
...
</body>
This is used to force the browser title to be set to the page title for a page loaded into a frame.
The index.html page is setup as follows:
<head>
<script language=JavaScript>
function SetPageTitle() {
document.title = Main.document.title;
}
</script>
</head>
<frameset cols="150,*">
<frame name="TOC" target="main" src="TOC.htm" scrolling="auto">
<frame name="Main" src="Home.htm" scrolling="auto" target="_self">
...
</frameset>
This is pretty straight forward and has worked fine (no comments about using frames please!!!!).
Very recently I signed up for my own domain name and setup web forwarding (frame forwarding) to cloak the target hosting site
So www.mydomain.com ==> www.isp.com/~me
The cloaking forces the browser to only show www.mydomain.com.
But now every page generates an error "Object doesn't support this property or method" for the call to SetPageTitle.
I'm really not sure why the forwarding causes this. If you bypass the domain and go to the target hosting site (i.e. www.isp.com/~me) the error does not occur. Similarly if I turn off frame forwarding and just use standard forwarding it id fone but the browser will show the real target URL. It also appears that firefox does not seem to have a problem whereas IE does but then again firefox does not seem to show a lot of scripting errors anyway.
I'm not totally sure what the frame forwarding does that could cause this, Can someone explain what is going on?