From: Doug M. <do...@cr...> - 2003-12-29 23:58:26
|
It is possible in IE. Not in NS 4.x and unsure in Mozilla. In IE: <SCRIPT LANGUAGE=JavaScript FOR=window EVENT=onbeforeunload> var strMsg = 'Press Cancel if you wish to save your form before leaving\nIf you press OK you will lose all unsaved information.'; if (!top.ButtonClicked) { window.event.returnValue = strMsg; } </SCRIPT> ----- Original Message ----- From: "Jesse Vitrone" <je...@6t...> To: "dynapi help" <dyn...@li...> Sent: Sunday, December 28, 2003 10:50 PM Subject: [Dynapi-Help] dynapi.onUnload question > I have a page where the user is moving some layers around, and I want to > make sure they save before they leave the page, so I'd like to promt > them with a warning if the page is unloading and they haven't saved. > > To do that, I need to stop the page from unloading if they want to > save. What can I do with dynapi.onUnload to stop the page from > unloading? Is it possible? > > Thanks in advance, > Jesse Vitrone > > > ------------------------------------------------------- > This SF.net email is sponsored by: IBM Linux Tutorials. > Become an expert in LINUX or just sharpen your skills. Sign up for IBM's > Free Linux Tutorials. Learn everything from the bash shell to sys admin. > Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click > _______________________________________________ > Dynapi-Help mailing list > Dyn...@li... > https://lists.sourceforge.net/lists/listinfo/dynapi-help > --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.556 / Virus Database: 348 - Release Date: 12/26/2003 |