java - JSF - base page refresh automatically after close popup window -
i have 3 pages
- main page
- popup page started main page using onclick javascript method (consists input , button)
- foo page
i'm creating form on main page, operations admin key needed, popup window opened button. when popup window filled, submitted , key found in database, popup window redirected foo page , closed. i'm on main page , need automatically refresh take changes.
i can't using onclick="window.opener.location.href='main.xhtml';
on button because quick there time delay find key in database.
do have suggestion?
how close it? injecting javascript after postback?
add function refreshes opener;
window.onbeforeunload = function() { window.opener.reload(true); }; window.close();
untested.
balusc right in comment, sufficient with
window.opener.reload(true); window.close();
Comments
Post a Comment