Using a class name in jQuery's .closest()

后端 未结 4 495
长情又很酷
长情又很酷 2020-12-25 12:16

I\'m attempting to do some calculations for a \"running total\", this is my code:

$(\'.quantity_input\').live(\'change\',function(){         
                       


        
4条回答
  •  無奈伤痛
    2020-12-25 12:49

    You don't need to use find. closest takes a context argument. that helps you narrow down the field of search. You should use that.

提交回复
热议问题