Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何使用 JavaScript 检查 iCheck 复选框?已经试过代码:
document.getElementById("checkbox").checked = true;
从文档:
$('input').iCheck('check');
最好阅读您在网上找到的任何插件的文档,因为它们通常包含许多问题的答案,从而避免了在论坛中提问的需要。
使用$(element).iCheck('check');whereelement替换为所需的元素,例如document.getElementById('elementIdHere').
$(element).iCheck('check');
element
document.getElementById('elementIdHere')