两因素插件wordpress

问题描述

我为我的网站 wordpress 使用了两个因素插件。我试图改变一些功能。我在参数 $message 中使用 \n 添加了两个带换行符的句子,但我在电子邮件中收到了一个句子。这个功能

public function generate_and_email_token( $user ) {
$token = $this->generate_token( $user->ID );


$subject = wp_strip_all_tags( sprintf( __( 'Your login confirmation code for %s','two-factor' ),get_bloginfo( 'name' ) ) );

$message = wp_strip_all_tags( sprintf( __( 'Your verification code is: %s.\n','We ask you to receive our best regards.',$token ) );


$subject = apply_filters( 'two_factor_token_email_subject',$subject,$user->ID );


$message = apply_filters( 'two_factor_token_email_message',$message,$token,$user->ID );

return wp_mail( $user->user_email,$message );
}

我会用另一个函数改变字符串函数,但我不知道。

任何帮助!!

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)