Javascript close pop-up window and refresh parent window
die( "<-script->window.opener.location.reload();window.close();
<-/script->");
modify_index.php in edtech's admin_data area and change_password.php in Pt. Loma's eportfolio projects are examples of where I used this technique.
>>>>>added 1-26-2006 >>>
Here is the JAVASCRIPT used to create the pop-up window that will close using the PHP/Javascript code above. I used this "resizable", "scrollable" pop-up window when creating the Helix GED628 syllabus page:
v a r openWin;
function winOpen(href, target, width, height, resize, scrollbars) {
if (openWin && !openWin.closed) {
openWin.close();
}
openWin = window.open(href, target, 'width=' + width + ',height=' +
height + ',resizable=' + resize + ',scrollbars=' + scrollbars);
}
a href="change_password.php?uid=" target="changepassword" onClick="winOpen(this.href,
this.target, 400, 140, 'yes', 'yes'); return false;"change /a
0 Comments:
Post a Comment
<< Home