public function actionCreate() { $model = new CmsPage(); $model->attributes = $_POST; $model->SaveImage(); if ($model->save()) { $this->sendResponse($model); } }