The code below works fine on IE and FF but not on Google Chrome. Please can someone help me to find out the mistake?.Thanks In Advance.
Flex Code: Public function init():void { ExternalInterface.addCallback("getCloseConfirmMessage", closeConfirmMessage); ExternalInterface.call("setUpBeforeUnload",FlexGlobals.topLevelApplication.id); } Public function closeConfirmMessage():void { //DB updation code }
Java Script : <script language="javascript" type="text/javascript"> var fxControl; function confirmClose() { alert("Please click OK to end the session"); fxControl.getCloseConfirmMessage(); }; function setUpBeforeUnload( appName ) { fxControl = document[ appName ] || window[ appName ]; window.onbeforeunload = confirmClose; }; </script>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)