Wait! Looks like we don't have enough information to add this to bug database. Please follow this template bug format.
  1. #1
    Ext JS Premium Member
    Join Date
    Sep 2007
    Location
    CT
    Posts
    462
    Vote Rating
    3
    ValterBorges is on a distinguished road

      0  

    Default Alert leaving page raising event twice in ie7/8

    Extjs v 4.0.2
    IE 8
    IE 7

    Tested in IE9, FireFox 3.6,4.0,Safari,Chrome works fine.


    The following line is causing multiple onwindowunloading.


    function onWindowUnloading(e) {

    e.browserEvent.returnValue = "Alert: Any unsaved work will be lost";

    }



    //This is the called in the app.

    Ext.EventManager.on(window,'beforeunload',onWindowUnloading);

  2. #2
    Sencha - Services Team hendricd's Avatar
    Join Date
    Aug 2007
    Location
    Long Island, NY USA
    Posts
    5,965
    Vote Rating
    12
    hendricd will become famous soon enough hendricd will become famous soon enough

      0  

    Default

    How about simply:
    Code:
    function onWindowUnloading(e) {
    
         return "Alert: Any unsaved work will be lost";
    
    }
    ... making sure it's placed in a <head><script> tag block.
    "be dom-ready..."
    Doug Hendricks

    Maintaining ux: ManagedIFrame, MIF2 (FAQ, Wiki), ux.Media/Flash, AudioEvents, ux.Chart[Fusion,OFC,amChart], ext-basex.js/$JIT, Documentation Site.


    Got Sencha licensing questions? Find out more here.


  3. #3
    Ext JS Premium Member
    Join Date
    Sep 2007
    Location
    CT
    Posts
    462
    Vote Rating
    3
    ValterBorges is on a distinguished road

      0  

    Default alert leaving page

    that doesn't work in firefox.

Thread Participants: 1