weird thing

Hello everyone.

Can anyone tell me why when I use $model->attributes=$_POST[‘VvidForm’]; in my controller only those attributes are accepted that are mentioned in rules() in my VvidForm model that extends CFormModel?


that’s simply by design… if you want to match all your attributes just set them as ‘safe’ inside the rules… you can look here: