function ff_setSelected(name, list)
{
    ids = list.split(',')
    opts = ff_getElementByName(name).options;
    for (o = 0; o < opts.length; o++) {
        state = false;
        for (i = 0; i < ids.length; i++) 
            if (ids[i]==opts[o].value) {
                state = true;
                break;
            } // if
        opts[o].selected = state;
    } // for
} // ff_setSelected