Hello Everyone
I am new to Yii and I am affair after trying to resolve my problem, that I am over complicating the issue. I have 3 checkboxes setup in TBActiveForm and because the inlineCheckBoxList is looking for a string I added this code into the model
public function beforeValidate()
{
$this->shipping = implode(', ',$this->shipping);
return parent::beforeValidate();
}
That got me through the first problem fine and when I select one box it works perfectly. My problem is when I have 2 boxes checked. It safes to the database like it should, but when the page is refreshed, no boxes are checked, ever though it is in the database. Example: I have selected option 1 and 3, in the database 1, 3, return displays nothing. I am sure that this is not difficult to do, but somehow I am making it that way Thank you for any guidance you can provide.
<?php echo $form->inlineCheckBoxList($model,'shipping',array(
'1'=>'One',
'2'=>'Two',
'3'=>'Three'),
array(
'empty'=>'','multiple'=>true , 'span'=> 4));?>
Michael