
Originally Posted by
mburt
Try this:
Code:
window.onload=function() {return parent.location;}
It may override it, I'm not sure. It tries to return the default value of parent.location.
That won't do anything except possibly interfere with other onload calls.
If you have access to the script:
Code:
<script language="JavaScript" type="text/javascript" >
// This script makes sure that our top level frame is not within
// some unknown frame which may mess up the viewability due to it
// being smaller than we need. This would be useful if someone
// else has a link to this page within a frame window.
if (parent.location != self.location)
{
parent.location = self.location.href
}
You could edit it, something like so:
Code:
<script language="JavaScript" type="text/javascript" >
// This script makes sure that our top level frame is not within
// some unknown frame which may mess up the viewability due to it
// being smaller than we need. This would be useful if someone
// else has a link to this page within a frame window.
if (parent.location != self.location && parent.location.href.indexOf('something')<0)
{
parent.location = self.location.href
}
What you put for:
something
could be the name of the top page that you want to have override this or, the name of the domain that the top page is on. For example, if your domain is:
somedomain.com
Do it like so:
Code:
if (parent.location != self.location && parent.location.href.indexOf('somedomain.com')<0)
Bookmarks