icklechurch
06-19-2009, 09:31 AM
Hi,
I have a pop-up window that I want to auto refresh the parent page when it is shut.
At the moment I am using the code below to do this if the user clicks a 'close window' link in the popup. BUT is there a way to auto refresh the parent page if the user just clicks the red cross at the top right of the popup?
<script>
function closePopup(){
window.opener.location.href = window.opener.location.href;
window.opener.focus();
window.close();
}
</script>
I have a pop-up window that I want to auto refresh the parent page when it is shut.
At the moment I am using the code below to do this if the user clicks a 'close window' link in the popup. BUT is there a way to auto refresh the parent page if the user just clicks the red cross at the top right of the popup?
<script>
function closePopup(){
window.opener.location.href = window.opener.location.href;
window.opener.focus();
window.close();
}
</script>