forked from extern/egroupware
fixed proxy to to add options to a selectbox, needed by IE ;-)
This commit is contained in:
parent
21f71e934c
commit
68074ad82e
@ -80,18 +80,12 @@ function activate_tab(tab,all_tabs,name)
|
|||||||
function selectbox_add_option(id,label,value,do_onchange)
|
function selectbox_add_option(id,label,value,do_onchange)
|
||||||
{
|
{
|
||||||
selectBox = document.getElementById(id);
|
selectBox = document.getElementById(id);
|
||||||
|
/*alert('selectbox_add_option('+id+','+label+','+value+') '+selectBox);*/
|
||||||
for (i=0; i < selectBox.length; i++) {
|
for (i=0; i < selectBox.length; i++) {
|
||||||
if (selectBox.options[i].value == value) {
|
if (selectBox.options[i].value == value) {
|
||||||
selectBox.options[i].selected = true;
|
selectBox.options[i].selected = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
else if (value.slice(0,1) == "," && selectBox.options[i].value.slice(0,1) == ",") {
|
|
||||||
selectBox.options[i].value = value;
|
|
||||||
selectBox.options[i].text = "multiple*";
|
|
||||||
selectBox.options[i].title = label;
|
|
||||||
selectBox.options[i].selected = true;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if (i >= selectBox.length) {
|
if (i >= selectBox.length) {
|
||||||
selectBox.options[selectBox.length] = new Option(label,value,false,true);
|
selectBox.options[selectBox.length] = new Option(label,value,false,true);
|
||||||
|
Loading…
Reference in New Issue
Block a user