1

ケーキのメールが機能しない

ここにコード app/config/email.php があります

public $default = array(
    'transport' => 'Mail',
    'from' => 'abcd@gmail.com',
    //'charset' => 'utf-8',
    //'headerCharset' => 'utf-8',
);

そして app/controller/UsersController で

email = new CakeEmail();
                $email->template('activate_your_account', 'default')
                        ->config('smtp')
                        ->emailFormat('html')
                        ->subject(__('Account Verification - ' . Configure::read('Application.name')))
                        ->to($user)
                        ->from(Configure::read('Application.from_email'))
                        ->viewVars(array('hash' => $hash, 'id' => $id))
                        ->send();

これを実行すると、次のようなエラーが発生しますAn internal error has occurred。それを手伝ってください。

編集:今、私はこのエラーを解決しましたありがとう

4

1 に答える 1