Javascript. But it can be a little tricky depending upon the exact circumstances and will only work when users have javascript enabled. If it's really critical though, we can make it so that users without javascript will only see a statement saying that javascript is required to view this page. They will see that regardless of whether or not the page is in the iframe. And, it has to be a page. Your post indicates it might simply be an image. If so, just use an image tag and skip the iframe.
I imagine your home page has a name like index.html or index dot something. It could have a different filename, like home dot something. There are various filenames that will load as the default page in a folder and your home page is probably one of these. That means - say it's index.htm, that it can be accessed as:
Code:
http://www.mydomiain.com/index.htm
or as just:
Code:
http://www.mydomiain.com/
So, if it's like that, on the page in the iframe, put this script in the head (substitute the actual addresses for the ones shown):
Code:
<script type="text/javascript">
if(top.location.href !== 'http://www.mydomiain.com/' && top.location.href !== 'http://www.mydomiain.com/index.htm'){
location.href = 'http://www.mydomiain.com/';
}
</script>
If you're interested in making the page virtually inaccessible for folks without javascript, let me know.
Bookmarks