|
@@ -144,10 +144,10 @@ class MailCaptcha extends BaseService
|
|
$mail->Username = config('smtp.username'); //SMTP username
|
|
$mail->Username = config('smtp.username'); //SMTP username
|
|
$mail->Password = config('smtp.password');
|
|
$mail->Password = config('smtp.password');
|
|
$mail->SMTPSecure = PHPMailer::ENCRYPTION_SMTPS; //Enable implicit TLS encryption
|
|
$mail->SMTPSecure = PHPMailer::ENCRYPTION_SMTPS; //Enable implicit TLS encryption
|
|
- $mail->Port = 465; //TCP port to connect to; use 587 if you have set `SMTPSecure = PHPMailer::ENCRYPTION_STARTTLS`
|
|
|
|
|
|
+ $mail->Port = config('smtp.port'); //TCP port to connect to; use 587 if you have set `SMTPSecure = PHPMailer::ENCRYPTION_STARTTLS`
|
|
|
|
|
|
//Recipients
|
|
//Recipients
|
|
- $mail->setFrom('zhangdehua814@163.com', 'Mailer');
|
|
|
|
|
|
+ $mail->setFrom(config('smtp.from_address'), config('smtp.from_name'));
|
|
$mail->addAddress($email, $name); //Add a recipient
|
|
$mail->addAddress($email, $name); //Add a recipient
|
|
|
|
|
|
//Content
|
|
//Content
|