謝晒的PHP網頁設計
聯絡E-mail:
sean0704@gmail.com
Friday, February 6, 2015
[jQuery] 判斷 checkbox 被選取了幾個 (checked) (常用於表單檢查 "至少要選取一個 才能送出" )
if($("input[name='id[]']:
check
ed").length == 0) {
alert("請至少選擇一個ID");
return false;
}
No comments:
Post a Comment
‹
›
Home
View web version
No comments:
Post a Comment