Hi John, On Fri, 26 Aug 2011, John Spackman wrote:
> If the unload does not fire because it's not an html page, what happens if > the URL passed to window.open is an html file which then does a meta or > javascript redirect to the .doc file? this works as follows: - If the .doc file exists and is successfully loaded, the onload handler is NOT called. Therefore, with a long enough timeout for the call to the external application to return, I can then call win.close() on the html window. - If the .doc file doesn't exist, the load handler IS called and I can then either leave the window open to display the 404 error or I close it and create my own (Qooxdooish) error popup. I assume that would also work for other HTTP errors. I am still worried about the timeout based call to win.close(), because if I don't wait long enough the window could already be closed before the HTTP error occurs and neither the user nor I would see it as the load event isn't caught anymore. Cheers, Fritz > On 26/08/2011 08:46, "Fritz Zaucker" <[email protected]> wrote: > >> On Fri, 26 Aug 2011, thron7 wrote: >> >>> >>> >>> On 08/26/2011 09:08 AM, Fritz Zaucker wrote: >>>> P.S.: I tried all kind of things like first opening the window with a >>>> dummy >>>> html page and the do a window.location.replace('test.doc') >>>> inside and >>>> outside the event handler, unfortunately without any success. >>> >>> Do you put the "window.location.replace()" call inside the dummy html >>> page? >>> >>> T. >> >> Tried that, still no onload event. >> >> One workaround I found is closing the about:blank window with a timer. >> >> But I still don't understand that bevaviour. >> >> Cheers, >> Fritz >> >> -- >> Oetiker+Partner AG tel: +41 62 775 9903 (direct) >> Fritz Zaucker +41 62 775 9900 (switch board) >> Aarweg 15 +41 79 675 0630 (mobile) >> CH-4600 Olten fax: +41 62 775 9905 >> Schweiz web: www.oetiker.ch >> >> -------------------------------------------------------------------------- >> ---- >> EMC VNX: the world's simplest storage, starting under $10K >> The only unified storage solution that offers unified management >> Up to 160% more powerful than alternatives and 25% more efficient. >> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev >> _______________________________________________ >> qooxdoo-devel mailing list >> [email protected] >> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel > > > > > ------------------------------------------------------------------------------ > EMC VNX: the world's simplest storage, starting under $10K > The only unified storage solution that offers unified management > Up to 160% more powerful than alternatives and 25% more efficient. > Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev > _______________________________________________ > qooxdoo-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel > > -- Oetiker+Partner AG tel: +41 62 775 9903 (direct) Fritz Zaucker +41 62 775 9900 (switch board) Aarweg 15 +41 79 675 0630 (mobile) CH-4600 Olten fax: +41 62 775 9905 Schweiz web: www.oetiker.ch ------------------------------------------------------------------------------ EMC VNX: the world's simplest storage, starting under $10K The only unified storage solution that offers unified management Up to 160% more powerful than alternatives and 25% more efficient. Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
