/** * Overridden implementation of setValue which sets the 'value' of the * attribute for the ZFormWebElement * * @param string $value * @return void */ public function setValue($value) { parent::setValue($value); if ($value) { $this->checked = true; } else { unset($this->_attributes['checked']); } }
/** * Overrides setValue in the parent to also set the checked status of * the ZCheckBox. */ public function setValue($value) { parent::setValue($value); if ($value) { $this->setChecked(true); } else { $this->setChecked(false); } }