/** * Конструктор * @param mixed ID */ public function __construct($id, $multy = false) { parent::__construct($id); $this->setAttribute("name", $this->id); if ($multy) { $this->setAttribute("name", $this->id . '[]'); $this->setAttribute("multiple", 'multiple'); } }
/** * Конструктор * @param string ID компонента * @param string Разделитель между кнопками */ public function __construct($id, $delimiter = '') { parent::__construct($id); $this->delimiter = $delimiter; }