2012-09-21 13:03:27 +02:00
|
|
|
function getCheckedValuesByName(checkboxname) {
|
|
|
|
var e=document.getElementsByName(checkboxname);
|
|
|
|
var p="";
|
|
|
|
|
|
|
|
for (var j=0;j<e.length;j++) {
|
|
|
|
if (e[j].checked) p+=e[j].value+" ";
|
|
|
|
};
|
|
|
|
return p;
|
|
|
|
}
|
|
|
|
|
2012-12-01 23:36:43 +01:00
|
|
|
function checkAllBoxes(checkboxname,checked) {
|
|
|
|
var e=document.getElementsByName(checkboxname);
|
|
|
|
|
|
|
|
for (var j=0;j<e.length;j++) {
|
|
|
|
e[j].checked=checked;
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
2012-10-18 00:49:13 +02:00
|
|
|
function getSelectedValueById(selectname,idx) {
|
|
|
|
if (idx == undefined) idx = 0;
|
2012-09-21 13:03:27 +02:00
|
|
|
var i=document.getElementById(selectname).selectedIndex;
|
2012-10-18 00:49:13 +02:00
|
|
|
return document.getElementById(selectname).options[i+idx].value;
|
2012-09-21 13:03:27 +02:00
|
|
|
}
|
2012-11-19 23:52:30 +01:00
|
|
|
|
|
|
|
function checkEnter(event) {
|
|
|
|
event=event || window.event;
|
|
|
|
getEvent=event.keyCode;
|
|
|
|
if (getEvent == "13") {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|