首页 > 语言 > JavaScript > 正文

用Javascript读取CheckBox数组的值的代码(兼容IE与firefox)

2024-05-06 14:25:47
字体:
来源:转载
供稿:网友
document.getElementsByName(name)方法正是用来读取对象数组的。用法如下:
var elements = document.getElementsByName("role");
("role"为CheckBox数组中每个CheckBox共同的名字)
for:

[Ctrl+A 全选 注:如需引入外部Js需刷新才能执行]
发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表

图片精选