I have a problem when using checkBoxList

I have a problem when using CActiveForm.checkBoxList

view file:

<?php echo $form->checkBoxList($model,'rightArray',array(





                    ),array('separator'=>'<br />','template'=>'{input} {label}')); ?>

model file:

class Manager extends CActiveRecord



     * Property in Model but not in DB


    public $password2;

    public $rightArray=array();

    //public $rightArray;

    //i tried both


controller file:



after submit, var_dump()'s output:

  public 'rightArray' => 



i can get all other property expect this checkBoxList.

if i use:




it worked.

anybody help?

Do you have a validation rule for rightArray ?

Problem solved.

it’s because i haven’t give rightArray a rule.

so after i add


in rules.

it worked.

thank 古井好月!

no. i added the rule and it worked.

thank you for you help! ;D