Catch display_name in wordpress

Asked

Viewed 21 times

1

Next, when a user registers on my site, he receives a welcome email, I’m using a plugin (Buddypress) that sends me this welcome email, using a filter that made it available I’m changing the e-welcome mail to display the user’s display_name instead of the email (in the message body).

Example: Hello, [email protected], and I want it to appear, Hello, Eunice Negris Lima. (which is the name she signed up for)

ID | display_name
95 | Eunice Negris Lima

I would like to know how I get this information from the bank or whatever function I use.

Thank you.

1 answer

1


You can use the global variable $current_user->display_name;

Browser other questions tagged

You are not signed in. Login or sign up in order to post.