Answers for "get user first name of current user wordpress"

PHP
0

get current user first and last name wordpress

$current_user = wp_get_current_user();
    
    echo 'Username: ' . $current_user->user_login . '<br />';
    echo 'User email: ' . $current_user->user_email . '<br />';
    echo 'User first name: ' . $current_user->user_firstname . '<br />';
    echo 'User last name: ' . $current_user->user_lastname . '<br />';
    echo 'User display name: ' . $current_user->display_name . '<br />';
    echo 'User ID: ' . $current_user->ID . '<br />';
Posted by: Guest on February-24-2021
1

wordpress get username

$current_user = wp_get_current_user();
echo($current_user->user_login);
Posted by: Guest on January-29-2021

Code answers related to "get user first name of current user wordpress"

Browse Popular Code Answers by Language