receivers = $attributes['receivers'];
$this->receivers_selected = $attributes['receivers_selected'];
unset($attributes['receivers']);
unset($attributes['receivers_selected']);
$this->HTML_QuickForm_element($elementName, $elementLabel, $attributes);
$this->_persistantFreeze = true;
$this->_appendName = true;
$this->_type = 'receivers';
}
/**
* Create the form elements to build this element group
*/
function _createElements()
{
$this->_elements[] = new HTML_QuickForm_Radio('receivers', '', get_lang('Everybody'), '0', array ('onclick' => 'javascript:receivers_hide(\'receivers_to\')'));
$this->_elements[0]->setChecked(true);
$this->_elements[] = new HTML_QuickForm_Radio('receivers', '', get_lang('SelectGroupsUsers'), '1', array ('onclick' => 'javascript:receivers_show(\'receivers_to\')'));
$this->_elements[] = new HTML_QuickForm_advmultiselect('to', '', $this->receivers);
$this->_elements[2]->setSelected($this->receivers_selected);
}
/**
* HTML representation
*/
function toHtml()
{
include_once ('HTML/QuickForm/Renderer/Default.php');
$this->_separator = '
';
$renderer = & new HTML_QuickForm_Renderer_Default();
$renderer->setElementTemplate('{element}');
$select_boxes = $this->_elements[2];
$select_boxes->setElementTemplate('