Bind multiple events to jQuery 'live' method

后端 未结 4 2009
梦谈多话
梦谈多话 2020-12-31 03:34

jQuery\'s \'live\' method is unable to handle multiple events. Does anyone know of a good workaround to attach multiple events to a function that polls current and future el

4条回答
  •  北海茫月
    2020-12-31 04:15

    Try in this way:

    ("#button").bind("click keyup", function(){
    
    // your code goes here
    
    }) 
    

提交回复
热议问题