Beispiel #1
0
 public function actionSaveEmail()
 {
     $model = new EmailForm();
     if ($model->load(Yii::$app->request->post()) && $model->update()) {
         return $this->redirect(['default/index']);
     }
 }
Beispiel #2
0
 public function actionIndex()
 {
     $model = new EmailForm();
     if ($model->load(Yii::$app->request->post()) && $model->update()) {
         return $this->redirect(['index']);
     } else {
         return $this->render('index', ['model' => $model]);
     }
 }