[Phpmyadmin-devel] js question

Marc Delisle DelislMa at CollegeSherbrooke.qc.ca
Sun Dec 30 14:18:01 CET 2001


Hi,

in user_details.js there is this function:
-------------------------------------
function checkForm(the_form, do_check) {
    var elts      = document.forms[the_form].elements;
    var elts_cnt  = elts.length;
    for (var i = 0; i < elts_cnt; i++) {
        var whichElt = elts[i].name;
        if (whichElt.indexOf('_priv') >= 0) {
            document.forms[the_form].elements[whichElt].checked =
do_check;
        } // end if
    } // end for

    return true;
} // end of the 'checkForm()' function
-------------------------------------

I would like to do the same thing, but in a form where the field names
are "selected_tbl[]". How
can I refer to those fields in the form?

Marc






More information about the Developers mailing list