Yes, it works.

Thx.

On 1/19/07, Sam Collett <[EMAIL PROTECTED]> wrote:

On 19/01/07, Unai Martinez <[EMAIL PROTECTED]> wrote:
> I get it working, without jquery :: window.onbeforeunload =
> function(){return "Unsaved changes."}
>
> Thx.

Perhaps it should be filed as a bug?

$(window).bind("beforeunload", function(){return "Unsaved changes."; });

The above 'sort of' worked in jQuery 1.0.2 tested - you got the dialog
box, but the text "Unsaved changes" was not shown. Now it doesn't work
this way in jQuery 1.1 at all.

This does work though:

$(window).bind("beforeunload", function(e){e.returnValue = "Unsaved
changes."; });

_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/




--
Unai Martinez
[EMAIL PROTECTED]
http://helusinfa.blogspot.com
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

Reply via email to