licwid
03-15-2005, 12:57 AM
yes yes dont shoot me i know iframes/frames suck but i'm using them save bandwidth for me and users.
anyways
http://www.customdc5.com is the site
what i'm trying to do is setup a script that will detect if the page is loaded as the parent, and if so, redirect to the main page and load itself into the iframe. so if you just key in http://www.customdc5.com/videos/index.html, you will get the page as i intended it to be (in the iframe)
<script language="JavaScript">
if (parent.location.href == self.location.href) {
window.location.href = 'index.html';
}
</script>
the redirect is simple, i know, but how can i (can i??) make it load itself into the iframe when it redirects?
anyways
http://www.customdc5.com is the site
what i'm trying to do is setup a script that will detect if the page is loaded as the parent, and if so, redirect to the main page and load itself into the iframe. so if you just key in http://www.customdc5.com/videos/index.html, you will get the page as i intended it to be (in the iframe)
<script language="JavaScript">
if (parent.location.href == self.location.href) {
window.location.href = 'index.html';
}
</script>
the redirect is simple, i know, but how can i (can i??) make it load itself into the iframe when it redirects?