using "return false" in my event handler

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dmjpro
    Top Contributor
    • Jan 2007
    • 2476

    using "return false" in my event handler

    what concept i have that when i wrting my own event handler then if my handler returns false then the default event handler will no more execute.
    so i can stop the window default behaviours
    sometimes i get the fruitful result but sometimes not

    as for example ....

    <body onunload = test>

    function test()
    {
    alert(message); //flashes the message but i can't stop the defalut behaviours
    return false;
    }

    i mean to say that the page cann't refreshed or not to closed
    is it possible friends

    plz help me out .....
    thanks in advance
  • dorinbogdan
    Recognized Expert Contributor
    • Feb 2007
    • 839

    #2
    Please take a look at:
    http://www.webreferenc e.com/dhtml/diner/beforeunload/bunload4.html

    It may be related and helpful (using onbeforeunload event).

    Comment

    • dmjpro
      Top Contributor
      • Jan 2007
      • 2476

      #3
      thanks for reply

      Comment

      Working...