hello;) i have code like below. I need to simulate click on #log_in button when i press enter on input fields. My code doesnt work. Why ? What can i do to make this works ?
[cut] $(this.elContainer).down('#log_in').observe('click', function() { this.login(); }.bind(this)); $(this.elContainer).select('input').each(function(el){ el.observe('keypress', function(event) { if(event.keyCode == '13') { $(this.elContainer).down('#log_in').fire('click'); //this.login(); //Event.stop(event); } }.bind(this)); }.bind(this)); [cut] --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~----------~----~----~----~------~----~------~--~---