PaleSeptember
Technical User
I am creating a website with an iframe.
The parent page has layers that are visible or hidden depending on user action.
If a visiter refreshes the page, then the parent page reverts to it's original state which is not always appropriate therefore I would like the child page only to refresh when the visitor refreshes the page.
I am using a javascript code to ensure the page refreshes within the parent page but I don't know which bit of the code (if any) I can alter to stop the parent page refreshing at the same time.
If this is not possible, could you tell me which bit of the code to change so that on refresh the parent page reverts to its original iframe source, not the current one.
Thank you for your help.
BTW idiot's guide needed here as you can probably tell by my wording.
The parent page has layers that are visible or hidden depending on user action.
If a visiter refreshes the page, then the parent page reverts to it's original state which is not always appropriate therefore I would like the child page only to refresh when the visitor refreshes the page.
I am using a javascript code to ensure the page refreshes within the parent page but I don't know which bit of the code (if any) I can alter to stop the parent page refreshing at the same time.
Code:
<script type="text/javascript">
pageLoc = self.location;
pageAdd = top.location;
if (pageLoc == pageAdd) {
contentSrc = escape(pageLoc);
contPage = 'index.html?' ;
top.location.href = contPage;
}
</script>
If this is not possible, could you tell me which bit of the code to change so that on refresh the parent page reverts to its original iframe source, not the current one.
Thank you for your help.
BTW idiot's guide needed here as you can probably tell by my wording.