$('input').bind('change', function() { //... }); or
$('input').change(function() { //... }); See http://docs.jquery.com/Events/bind#typedatafn and a full list of Event Helpers, such as http://docs.jquery.com/Events/blur#fn http://docs.jquery.com/Events/change#fn http://docs.jquery.com/Events/click#fn http://docs.jquery.com/Events/dblclick#fn ... on http://docs.jquery.com/Events - Richard On Tue, Aug 11, 2009 at 2:28 AM, André Hänsel <an...@webkr.de> wrote: > > Hi list, > > which is the recommended way to bind event handlers to elements. > Preferably without giving each of them an id. > > As far as I know, the "classic" way (<input onchange="...">) is > considered deprecated and evil. So what is the jQuery way of doing > this? > > Regards, > André >