企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
#### 一、配置smtp 在`common/config/main-local.php`里添加: ~~~ 'components' => [ 'mailer' => [ 'class' => 'yii\swiftmailer\Mailer', 'useFileTransport' => false, //这句一定有,false发送邮件,true只是生成邮件在runtime文件夹下,不发邮件 'transport' => [ 'class' => 'Swift_SmtpTransport', 'host' => 'smtp.sina.cn', //每种邮箱的host配置不一样 'username' => '18503060358@sina.cn', 'password' => '********', 'port' => '465', 'encryption' => 'ssl', ], 'messageConfig' => [ 'charset' => 'UTF-8', 'from' => ['18503060358@sina.cn' => 'akun'] ], ], ] ~~~ #### 二、