Next, let me bring your attention to the other groupings that I have implemented in the example:
<?php
// snip
// create a checkbox group
$obj_genre[] = &HTML_QuickForm::createElement('checkbox', 'Alternative', null, 'Alternative');
$obj_genre[] = &HTML_QuickForm::createElement('checkbox', 'Hip-Hop', null, 'Hip-Hop');
$obj_genre[] = &HTML_QuickForm::createElement('checkbox', 'Other', null, 'Other');
$obj_registration_form->addGroup($obj_genre, 'chkGenre', 'Group Genre:', '<br />');
// create a radio button group
$obj_type[] = &HTML_QuickForm::createElement('radio', NULL, NULL, 'Male Solo', 'Male_Solo');
$obj_type[] = &HTML_QuickForm::createElement('radio', NULL, NULL, 'Female Solo', 'Female_Solo');
$obj_registration_form->addGroup($obj_type, 'radGroupType', 'Group Type:');
// create a multiple select drop down
$obj_registration_form->addElement('select', 'ddlLookingFor', 'Looking For:', array ("Publishing_Deal" => "Publishing Deal", "Label_Deal" => "Label Deal","Management_Deal" => "Management Deal", "Other" => "Other"), array("size" => "3", "multiple"));
// snip
?>
Here I have created a group of "checkbox" and "radio" <INPUT> elements using the createElement() static method. In this case, I have assigned the resultant element objects to an array. Next, I have passed this array of objects directly as input to the addGroup() method to render them in the browser. Note the use of a line break as a separator for the "checkbox" element - this displays each checkbox button on new line in the output.