[thelist] refesh parent window with javascript....

lon.kraemer lwkraemer at directvinternet.com
Fri Jun 28 14:52:01 CDT 2002


> i'm trying to get a popup window to refresh the parent window on
> closing.  it works in mozilla, but not ie6!  anyone know why??
>
> i'm using the following js function to open the window:
>
>    var openWin;
>
>    function winOpen(href, target, width, height) {
>       if (openWin && !openWin.closed) {
>          openWin.close();
>       }
>       openWin = window.open(href, target, 'width=' + width +
',height=' + height);

add: window.name = 'opener';

>    }
>
> called from a link like:
>
>    <a href="popup.aspx" target="detail" onclick="winOpen(this.href,
this.target, 650, 300); return false;">detail</a>
>
> then in popup.aspx i have a function that's called after everything's
> done:
>
>    function cancelPay() {
>       opener.location.reload(true);
>       window.close();
>    }

change to: window.opener.location.reload(true);

HTH





More information about the thelist mailing list