diff --git a/examples/chat.rb b/examples/chat.rb index 736165bd..4c8dfdfd 100755 --- a/examples/chat.rb +++ b/examples/chat.rb @@ -49,7 +49,7 @@ __END__ es.onmessage = function(e) { $('#chat').append(e.data + "\n") }; // writing - $("form").live("submit", function(e) { + $("form").submit(function(e) { $.post('/', {msg: "<%= user %>: " + $('#msg').val()}); $('#msg').val(''); $('#msg').focus(); e.preventDefault();