CakePHP: Clearing password field on failed submission

后端 未结 3 1243
南旧
南旧 2021-02-09 15:34

Greetings,

I am setting up a pretty standard registration form with password field.

The problem is, after a failed submission (due to empty field, incorrect form

3条回答
  •  余生分开走
    2021-02-09 15:40

    In your controller:

    function beforeRender() {
        parent::beforeRender();
        $this->data['Vendor']['password'] = '';
    }
    

提交回复
热议问题