html ( 使用 TP 标签 ) :

<volist name="health_tag" id="htag">
     <input type="checkbox" class="helth_tag" name="health_tag[]" value="{$htag}"/>{$htag}
</volist>

 

js:

if($("input[class='helth_tag']:checked").length == 0){

     alert("至少勾选一个健康标签!");
     return false;
}   

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-01-13
  • 2021-11-01
  • 2022-01-06
  • 2021-11-14
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-11-07
  • 2021-12-09
  • 2021-12-14
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案