new_user_email_admin_notice() - WordPress 函数参考中文文档

返回介绍

new_user_email_admin_notice()

发布于 2017-09-11 字数1416 浏览 847 评论 0

new_user_email_admin_notice()

Adds an admin notice alerting the user to check for confirmation email after email address change.


描述


源代码

File: wp-admin/includes/ms.php

function new_user_email_admin_notice() {
	global $pagenow;
	if ( 'profile.php' === $pagenow && isset( $_GET['updated'] ) && $email = get_user_meta( get_current_user_id(), '_new_email', true ) ) {
		/* translators: %s: New email address */
		echo '<div class="notice notice-info"><p>' . sprintf( __( 'Your email address has not been updated yet. Please check your inbox at %s for a confirmation email.' ), '<code>' . esc_html( $email['newemail'] ) . '</code>' ) . '</p></div>';
	}
}

更新日志

Version 描述
3.0.0 Introduced.

相关函数

Uses

  • wp-includes/l10n.php:
    __()
  • wp-includes/formatting.php:
    esc_html()
  • wp-includes/user.php:
    get_user_meta()
  • wp-includes/user.php:
    get_current_user_id()

User Contributed Notes

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

目前还没有任何评论,快来抢沙发吧!