【问题标题】:How change the password of default email wordpress?如何更改默认电子邮件wordpress的密码?
【发布时间】:2016-02-04 04:53:13
【问题描述】:

我的网站 Wordpress 有一个大问题,我更改了默认邮件 wordpress 的密码(第一次安装 wordpress 时使用的邮件)。 与登录我的网站相比,现在不可能向新用户发送邮件。

如何更改 wordpress 中默认邮件的密码? 发送邮件的配置文件(SMTP用户和密码)在哪里?

您好。

【问题讨论】:

  • 默认 wp 中不使用 smtp 详细信息
  • 我能解决这个问题吗? @大卫
  • 我真的不知道细节是什么,是你自己的smtp服务器还是外部服务?或者你正在使用php邮件?或者只是你在wordpress中丢失了admin账户的密码,这与发送电子邮件的php过程无关?

标签: wordpress email passwords smtp


【解决方案1】:

我找到了解决办法

这是一个带有 cmets 的代码 sn-p 示例,用于配置 WordPress 以发送 SMTP 电子邮件:

add_action( 'phpmailer_init', 'send_smtp_email' );
function send_smtp_email( $phpmailer ) {

// Define that we are sending with SMTP
$phpmailer->isSMTP();

// The hostname of the mail server
$phpmailer->Host = "smtp.example.com";

// Use SMTP authentication (true|false)
$phpmailer->SMTPAuth = true;

// SMTP port number - likely to be 25, 465 or 587
$phpmailer->Port = "587";

// Username to use for SMTP authentication
$phpmailer->Username = "yourusername";

// Password to use for SMTP authentication
$phpmailer->Password = "yourpassword";

// Encryption system to use - ssl or tls
$phpmailer->SMTPSecure = "tls";

$phpmailer->From = "you@yourdomail.com";
$phpmailer->FromName = "Your Name";
}

要使用此 sn-p,您需要根据您的电子邮件服务要求调整设置。请与您的主人确认。 sn-p 配置完成后,可以添加到主题的 functions.php 文件中。

【讨论】:

    猜你喜欢
    • 2019-05-25
    • 1970-01-01
    • 2021-11-18
    • 2011-10-19
    • 1970-01-01
    • 2019-01-06
    • 2023-01-11
    • 2013-08-30
    • 2019-07-04
    相关资源
    最近更新 更多