dc_jt Posted October 14, 2008 Share Posted October 14, 2008 Ive tried searching for this but still cant seem to get my page to refresh. Here is my setup. Page 1 contains the following link: <a href="#" style="cursor:pointer" onclick="MM_openBrWindow('/cms/_content/documents/upload-document.inc.php?iDocumentId=<?=$_GET['iDocumentId']?>&iCategoryId=<?=$_GET['iCategoryId']?>','cardimg','width=800,height=300')">Upload Document</a> This opens page 2 as a popup window. In page 2 I have the following to close the popup: <a onclick="JavaScript:refreshParent()" href="#">Close</a> And also have the following javascript within page 2: <script language="JavaScript"> <!-- function refreshParent() { window.opener.location.href = window.opener.location.href; if (window.opener.progressWindow) { window.opener.progressWindow.close() } window.close(); } //--> </script> This closes the popup but doesnt refresh page 1, any ideas why?? Thanks Quote Link to comment Share on other sites More sharing options...
dc_jt Posted October 14, 2008 Author Share Posted October 14, 2008 Ive sorted it by using window.opener.document.location.reload(true); on the a tag when closing the popup. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.