[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] hrm/inc check.js
From: |
Sigurd Nes |
Subject: |
[Phpgroupware-cvs] hrm/inc check.js |
Date: |
Fri, 01 Sep 2006 15:51:48 +0000 |
CVSROOT: /sources/phpgroupware
Module name: hrm
Changes by: Sigurd Nes <sigurdne> 06/09/01 15:51:48
Added files:
inc : check.js
Log message:
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/hrm/inc/check.js?cvsroot=phpgroupware&rev=1.1
Patches:
Index: check.js
===================================================================
RCS file: check.js
diff -N check.js
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ check.js 1 Sep 2006 15:51:48 -0000 1.1
@@ -0,0 +1,58 @@
+
+function check_all_radio(which)
+{
+ for (i=0; i<document.form.elements.length; i++)
+ {
+ if (document.form.elements[i].type == "radio" &&
document.form.elements[i].value == which)
+ {
+ document.form.elements[i].checked = true;
+ }
+ }
+}
+
+function check_all_checkbox(which)
+{
+ for (i=0; i<document.form.elements.length; i++)
+ {
+ if (document.form.elements[i].type == "checkbox" &&
document.form.elements[i].name.substring(0,which.length) == which)
+ {
+ if (document.form.elements[i].checked)
+ {
+ document.form.elements[i].checked = false;
+ }
+ else
+ {
+ document.form.elements[i].checked = true;
+ }
+ }
+ }
+}
+
+function check_all_radio2(which)
+{
+ for (i=0; i<document.form2.elements.length; i++)
+ {
+ if (document.form2.elements[i].type == "radio" &&
document.form2.elements[i].value == which)
+ {
+ document.form2.elements[i].checked = true;
+ }
+ }
+}
+
+function check_all_checkbox2(which)
+{
+ for (i=0; i<document.form2.elements.length; i++)
+ {
+ if (document.form2.elements[i].type == "checkbox" &&
document.form2.elements[i].name.substring(0,which.length) == which)
+ {
+ if (document.form2.elements[i].checked)
+ {
+ document.form2.elements[i].checked = false;
+ }
+ else
+ {
+ document.form2.elements[i].checked = true;
+ }
+ }
+ }
+}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] hrm/inc check.js,
Sigurd Nes <=