对于新添加的标签应用如下写法会失效:
  $('.class').on("click",function(){……});
相当于:
  $('.class').bind("click",function(){……});
下边的方法会生效:

  $(document).on("click",'.class',function(){……});
相当于:
  $('.class').live("click",function(){……});

新版本的jquery已经舍弃了live方法

相关文章:

  • 2022-12-23
  • 2022-02-09
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-11-20
  • 2021-11-04
  • 2022-12-23
  • 2021-08-29
  • 2021-11-23
  • 2022-12-23
  • 2021-12-04
相关资源
相似解决方案