1
Maybe XOOPS should replace (and suggest devs to do this in their modules) select multiple form elements with checkboxes? You know, doesn’t require user to ctrl-click multiple elements, without risk of losing those that have already been selected.
For now I can do it like this:
$users_tray = new XoopsFormElementTray(_AM_PFINWEST_FZESPH ,'');
$users_tray->addElement(new XoopsFormLabel('',''));
$checkbox3 = new XoopsFormCheckBox('', 'xoops_uid[]', $xoops_uids, '
');
while ($row_zesp=$xoopsDB->fetchArray($result)){
$checkbox3->addOption($row_zesp['uid'], $row_zesp['uname']);
}
$users_tray->addElement($checkbox3);
$users_tray->addElement(new XoopsFormLabel('','
'));
$form->addElement($users_tray);
demoExtend XoopsFormCheckBox (or XoopsFormSelect) class adding param to place checkbox elements into "overflow:scroll" with declared height and width.
By the way. It would be handy if XoopsForm renders the text assigned to the checkbox or radio clickable to select an option.
<input id=il type=checkbox name=lr value="lang_pl"><label for=il> Click to check the box label>