userpro_profile_data

Description

This function can output any profile information for a given user. For example, to display user’s display name, role, or any other custom field with PHP.

Usage

Parameters

  • $field – Custom field to retrieve
  • $user_id – User ID (required)

Returns

Return the value of custom field stored for that user (If it exists)

Examples

Display the user’s role of admin (User ID: 1)

Display user’s display name

Was this article helpful?

Related Articles

Leave A Comment?