\

Namespaces

um

Classes

Array2XML
UM_Emails_List_Table Class UM_Emails_List_Table
UM_Functions Class UM_Functions
UM_Roles_List_Table Class UM_Roles_List_Table
UM_Versions_List_Table Class UM_Versions_List_Table

Functions

account_activation_link_tags_patterns()

account_activation_link_tags_patterns( $placeholders) : array

UM Placeholders for activation link in email

Parameters

$placeholders

Returns

array

account_activation_link_tags_replaces()

account_activation_link_tags_replaces( $replace_placeholders) : array

UM Replace Placeholders for activation link in email

Parameters

$replace_placeholders

Returns

array

is_ultimatemember()

is_ultimatemember() : bool

Check if we are on UM page

Returns

bool

ultimatemember_check_username_exists()

ultimatemember_check_username_exists() : bool

Run check if username exists

Returns

bool

um_access_profile()

um_access_profile(int  $user_id) : mixed

Profile Access

Parameters

int $user_id

Returns

mixed

um_account_disable_name_fields()

um_account_disable_name_fields(array  $fields) : array

Disables first and last name fields in account page.

Parameters

array $fields

Returns

array

um_account_page_hidden_fields()

um_account_page_hidden_fields( $args) : mixed

Hidden inputs for account form

Parameters

$args

Returns

mixed

um_account_profile_noindex_value()

um_account_profile_noindex_value(mixed|int  $value) : int

Fix for the account field "Avoid indexing my profile by search engines".

Parameters

mixed|int $value

Returns

int

um_account_sanitize_data()

um_account_sanitize_data( $data) : mixed

Sanitize inputs on Account update.

Parameters

$data

Returns

mixed

um_account_updated_notification()

um_account_updated_notification( $user_id,  $changed) : mixed

Update Account Email Notification

Parameters

$user_id
$changed

Returns

mixed

um_action_request_process()

um_action_request_process() : mixed

Processes the requests of UM actions

Returns

mixed

um_add_custom_message_to_menu()

um_add_custom_message_to_menu(array  $sorted_menu_items, \stdClass  $args) : array

Add dynamic profile headers

Parameters

array $sorted_menu_items
\stdClass $args

Returns

array

um_add_edit_icon()

um_add_edit_icon( $args) : mixed

Display the edit profile icon

Parameters

$args

Returns

mixed

um_add_form_honeypot_css()

um_add_form_honeypot_css() : mixed

Makes the honeypot invisible

Returns

mixed

um_add_form_honeypot_js()

um_add_form_honeypot_js() : mixed

Empty the honeypot value

Returns

mixed

um_add_form_identifier()

um_add_form_identifier( $args) : mixed

Adds a form identifier to form

Parameters

$args

Returns

mixed

um_add_login_fields()

um_add_login_fields( $args) : mixed

Show Fields

Parameters

$args

Returns

mixed

um_add_profile_fields()

um_add_profile_fields( $args) : mixed

Show Fields

Parameters

$args

Returns

mixed

um_add_register_fields()

um_add_register_fields( $args) : mixed

Show Fields

Parameters

$args

Returns

mixed

um_add_security_checks()

um_add_security_checks( $args) : mixed

Adds a spam timestamp

Parameters

$args

Returns

mixed

um_add_submit_button_to_login()

um_add_submit_button_to_login( $args) : mixed

Show the submit button

Parameters

$args

Returns

mixed

um_add_submit_button_to_profile()

um_add_submit_button_to_profile( $args) : mixed

Show the submit button (highest priority)

Parameters

$args

Returns

mixed

um_add_submit_button_to_register()

um_add_submit_button_to_register( $args) : mixed

Show the submit button

Parameters

$args

Returns

mixed

um_add_update_notice()

um_add_update_notice(array  $args) : mixed

Add a notice to UM Form after submission

Parameters

array $args

Returns

mixed

um_admin_email()

um_admin_email() : mixed|string|void

Short for admin email

Returns

mixed|string|void

um_admin_user_actions_hook()

um_admin_user_actions_hook(array  $actions, int  $user_id) : array

Main admin user actions.

Parameters

array $actions
int $user_id

Returns

array

um_after_account_privacy()

um_after_account_privacy(mixed  $args) : mixed

Parameters

mixed $args

Returns

mixed

um_after_insert_user()

um_after_insert_user(int|\WP_Error  $user_id, array  $args, null|array  $form_data = null) : mixed

After insert a new user run at frontend and backend.

Parameters

int|\WP_Error $user_id
array $args
null|array $form_data

It's null in case when posted from wp-admin > Add user

Returns

mixed

um_after_login_submit()

um_after_login_submit( $args) : mixed

Display a forgot password link

Parameters

$args

Returns

mixed

um_after_user_account_updated_permalink()

um_after_user_account_updated_permalink(int  $user_id, array  $changes) : mixed

Update Profile URL, display name, full name.

Parameters

int $user_id

The user ID.

array $changes

An array of fields values.

Returns

mixed

um_allowed_redirect_hosts()

um_allowed_redirect_hosts(array  $hosts) : array

UM allowed hosts

Parameters

array $hosts

Allowed hosts.

Returns

array

um_avatar_defaults()

um_avatar_defaults( $avatar_defaults) : mixed

Do not apply to backend default avatars

Parameters

$avatar_defaults

Returns

mixed

um_before_account_delete()

um_before_account_delete() : mixed

Before delete account tab content

Returns

mixed

um_before_account_notifications()

um_before_account_notifications(array  $args = array()) : mixed

Before notifications account tab content.

Parameters

array $args

Throws

\Exception

Returns

mixed

um_before_update_profile()

um_before_update_profile(array  $changes, int  $user_id) : array

Filter before update profile to force utf8 strings

Parameters

array $changes
int $user_id

Returns

array

um_block_wpadmin_by_user_role()

um_block_wpadmin_by_user_role() : mixed

Checks if user can access the backend

Returns

mixed

um_browser_url_redirect_to()

um_browser_url_redirect_to( $args) : mixed

Add a force redirect to from $_get

Parameters

$args

Returns

mixed

um_can_edit_field()

um_can_edit_field( $data) : bool

Can edit field

Parameters

$data

Returns

bool

um_can_edit_my_profile()

um_can_edit_my_profile() : bool

Checks if user can edit his profile

Returns

bool

um_can_view_field()

um_can_view_field( $data) : bool

Can view field

Parameters

$data

Returns

bool

um_can_view_profile()

um_can_view_profile(int  $user_id) : bool

Checks if user can view profile

Parameters

int $user_id

Returns

bool

um_change_profile_cover_photo_label()

um_change_profile_cover_photo_label(array  $fields) : array

Add cover photo label of file size limit

Parameters

array $fields

Predefined fields

Returns

array

um_change_profile_photo_label()

um_change_profile_photo_label(array  $fields) : array

Add profile photo label of file size limit

Parameters

array $fields

Predefined fields

Returns

array

um_check_conditions_on_submit()

um_check_conditions_on_submit(array  $condition, array  $fields, array  $submitted_data, bool  $reset = false) : bool

Error processing: Conditions

Parameters

array $condition
array $fields
array $submitted_data
bool $reset

Throws

\Exception

Returns

bool

um_check_user_status()

um_check_user_status(int  $user_id, array  $args, null|array  $form_data = null) : mixed

Check user status and redirect it after registration

Parameters

int $user_id
array $args
null|array $form_data

Returns

mixed

um_clean_user_basename()

um_clean_user_basename( $value) : mixed|void

User clean basename

Parameters

$value

Returns

mixed|void

um_clean_user_basename_filter()

um_clean_user_basename_filter(string  $value, mixed  $raw) : string

Filter user basename.

Parameters

string $value
mixed $raw

Returns

string

um_clickable_links()

um_clickable_links( $s) : mixed

Convert urls to clickable links

Parameters

$s

Returns

mixed

um_closest_num()

um_closest_num( $array,  $number) : mixed

Find closest number in an array

Parameters

$array
$number

Returns

mixed

um_comment_link_to_profile()

um_comment_link_to_profile(string  $return, string  $author, string  $comment_id) : string

Control comment author display.

Parameters

string $return

The HTML-formatted comment author link.

string $author

The comment author's username.

string $comment_id

The comment ID as a numeric string.

Returns

string

um_conditional_nav_menu()

um_conditional_nav_menu( $menu_items,  $args) : mixed

Conditional menu items

Parameters

$menu_items
$args

Returns

mixed

um_control_admin_bar()

um_control_admin_bar(bool  $show) : bool

Hide admin bar appropriately

Parameters

bool $show

Returns

bool

um_convert_tags()

um_convert_tags( $content, array  $args = array(), bool  $with_kses = true) : mixed|string

Convert template tags

Parameters

$content
array $args
bool $with_kses

Returns

mixed|string

um_core_is_local()

um_core_is_local() : bool

Check if running local

Returns

bool

um_custom_wp_err_messages()

um_custom_wp_err_messages( $message) : string

Filter to customize errors

Parameters

$message

Returns

string

um_deprecated_function()

um_deprecated_function(string  $function, string  $version, string  $replacement = null) : mixed

Wrapper for deprecated functions so we can apply some extra logic.

Parameters

string $function
string $version
string $replacement

Returns

mixed

um_disable_native_email_notificatiion()

um_disable_native_email_notificatiion( $changed,  $user_id) : mixed

Disable WP native email notification when change email on user account

Parameters

$changed
$user_id

Returns

mixed

um_display_login_errors()

um_display_login_errors( $args) : mixed

Display the login errors from other plugins

Parameters

$args

Returns

mixed

um_dynamic_login_page_redirect()

um_dynamic_login_page_redirect(string  $redirect_to = '') : bool|mixed|string|void

Get where user should be headed after logging

Parameters

string $redirect_to

Returns

bool|mixed|string|void

um_dynamic_user_profile_pagetitle()

um_dynamic_user_profile_pagetitle( $title, string  $sep = '') : mixed|string

Fix for plugin "The SEO Framework", dynamic profile page title

Parameters

$title
string $sep

Returns

mixed|string

um_dynamic_user_profile_title()

um_dynamic_user_profile_title( $title, string  $id = '') : string

Try and modify the page title in page

Parameters

$title
string $id

Returns

string

um_edit_my_profile_cancel_uri()

um_edit_my_profile_cancel_uri(string  $url = '') : mixed|string|void

Remove edit profile args from url

Parameters

string $url

Returns

mixed|string|void

um_edit_profile_url()

um_edit_profile_url(int  $user_id = null) : string

Returns the edit profile link

Parameters

int $user_id

Returns

string

um_edit_url_field_value()

um_edit_url_field_value( $value,  $key) : string

Cleaning on XSS injection for url editing field

Parameters

$value
$key

Returns

string —

$value

um_editing_user_id_input()

um_editing_user_id_input( $args) : mixed

If editing another user

Parameters

$args

Returns

mixed

um_fetch_user()

um_fetch_user( $user_id) : mixed

Sets a specific user and prepares profile data and user permissions and makes them accessible.

Parameters

$user_id

(required) A user ID is required. This is the user's ID that you wish to set/retrieve

Returns

mixed

Examples

The example below will set user ID 5 prior to retrieving his profile information. <?php um_fetch_user(5); echo um_user('display_name'); // returns the display name of user ID 5 ?>

                                            
In the following example you can fetch the profile of a logged-in user dynamically. <?php um_fetch_user( get_current_user_id() ); echo um_user('display_name'); // returns the display name of logged-in user ?>

                                                

um_field_conditions_are_met()

um_field_conditions_are_met( $data) : bool

If conditions are met return true;

Parameters

$data

Returns

bool

um_field_non_utf8_value()

um_field_non_utf8_value(string  $value) : string

Filter non-UTF8 strings

Parameters

string $value

Returns

string

um_filter_get_avatar_url()

um_filter_get_avatar_url(string  $url, int  $id_or_email, array  $args) : string

Replace Gravatar image URL to Ultimate member profile image URL if setting "Use Gravatars?" disabled

Parameters

string $url
int $id_or_email
array $args

Returns

string

um_filter_search()

um_filter_search(string  $search) : string

Filters the search query.

Parameters

string $search

Returns

string

um_filtered_social_link()

um_filtered_social_link(string  $key, null|string  $match = null) : string

Show filtered social link

Parameters

string $key
null|string $match

Returns

string

um_filtered_value()

um_filtered_value( $key, bool  $data = false) : mixed|string|void

Get filtered meta value after applying hooks

Parameters

$key
bool $data

Returns

mixed|string|void

um_force_admin_bar()

um_force_admin_bar() : mixed

Fix permission for admin bar

Returns

mixed

um_force_utf8_fields()

um_force_utf8_fields(mixed  $value, array  $data, string  $type = '') : mixed

Force fields to use UTF-8 encoding

Parameters

mixed $value
array $data
string $type

Returns

mixed

um_force_utf8_string()

um_force_utf8_string(mixed  $value) : mixed

Force strings to UTF-8 encoded

Parameters

mixed $value

Returns

mixed

um_form_notices_additional_tags()

um_form_notices_additional_tags(array  $allowed_html, string  $context) : array

Extends allowed tags for displaying UM Form notices.

Parameters

array $allowed_html
string $context

Returns

array

um_form_register_redirect()

um_form_register_redirect() : mixed

Redirect from default registration to UM registration page

Returns

mixed

um_get_avatar()

um_get_avatar(string  $avatar = '', string  $id_or_email = '', string  $size = '96', string  $avatar_class = '', string  $default = '', string  $alt = '') : string

Get user UM avatars

Parameters

string $avatar
string $id_or_email
string $size
string $avatar_class
string $default
string $alt

Returns

string —

returns avatar in image html elements

um_get_avatar_uri()

um_get_avatar_uri( $image, string|array  $attrs) : bool|string

get avatar uri

Parameters

$image
string|array $attrs

Returns

bool|string

um_get_avatar_url()

um_get_avatar_url( $get_avatar) : mixed

get avatar URL instead of image

Parameters

$get_avatar

Returns

mixed

um_get_canonical_url()

um_get_canonical_url(string  $canonical_url, \WP_Post  $post) : string|bool

Fix SEO canonical for the profile page

Parameters

string $canonical_url

The canonical URL.

\WP_Post $post

Optional. Post ID or object. Default is global $post.

Returns

string|bool —

The canonical URL, or false if current URL is canonical.

um_get_core_page()

um_get_core_page( $slug, bool  $updated = false) : bool|mixed|string|void

Get core page url

Parameters

$slug
bool $updated

Returns

bool|mixed|string|void

um_get_cover_uri()

um_get_cover_uri( $image,  $attrs) : bool|string

get cover uri

Parameters

$image
$attrs

Returns

bool|string

um_get_current_page_type()

um_get_current_page_type() : string

Get current page type

Returns

string

um_get_custom_field_array()

um_get_custom_field_array( $array,  $fields) : mixed

Validate conditional logic

Parameters

$array
$fields

Returns

mixed

um_get_default_avatar_uri()

um_get_default_avatar_uri() : string

Default avatar URL

Returns

string

um_get_default_cover_uri()

um_get_default_cover_uri() : mixed|string|void

default cover

Returns

mixed|string|void

um_get_display_name()

um_get_display_name( $user_id) : string

Get a user's display name

Parameters

$user_id

Returns

string

um_get_domain_protocol()

um_get_domain_protocol() : string

Get server protocol

Returns

string

um_get_form_fields()

um_get_form_fields(string|array  $array, int  $form_id) : array|string

Get form fields

Parameters

string|array $array
int $form_id

Returns

array|string

um_get_host()

um_get_host() : mixed

Get user host

Returns the webhost this site is using if possible

Returns

mixed —

string $host if detected, false otherwise

um_get_locale()

um_get_locale() : string

Get localization

Returns

string

um_get_metadefault()

um_get_metadefault( $id) : string

Get meta option default

Parameters

$id

Returns

string

um_get_nav_menu_items()

um_get_nav_menu_items( $items,  $menu,  $args) : mixed

Conditional menu items

Parameters

$items
$menu
$args

Returns

mixed

um_get_option()

um_get_option( $option_id) : mixed|string|void

Get option value

Please use UM()->options()->get() instead

Parameters

$option_id

Returns

mixed|string|void

um_get_predefined_page_id()

um_get_predefined_page_id(string  $slug) : bool|int

Parameters

string $slug

Returns

bool|int

um_get_predefined_page_url()

um_get_predefined_page_url(string  $slug) : bool|string

Get predefined page URL

Parameters

string $slug

Returns

bool|string

um_get_redirect_url()

um_get_redirect_url(string  $key) : string

Set redirect key

Parameters

string $key

Returns

string —

$redirect_key

um_get_requested_user()

um_get_requested_user() : bool|null

Gets the requested user

Returns

bool|null

um_get_roles()

um_get_roles() : array

Get all UM roles in array

Returns

array

um_get_search_form()

um_get_search_form() : string

Returns the ultimate member search form

Returns

string

um_get_search_query()

um_get_search_query() : string

Returns the user search query

Returns

string

um_get_snippet()

um_get_snippet( $str, int  $wordCount = 10) : string

Get limit of words from sentence

Parameters

$str
int $wordCount

Returns

string

um_get_url_for_language()

um_get_url_for_language( $post_id,  $language) : bool|string

Get a translated core page URL

Parameters

$post_id
$language

Returns

bool|string

um_get_user_avatar_data()

um_get_user_avatar_data( $user_id = '',  $size = '96') : bool|string

get user avatar url

Parameters

$user_id
$size

Returns

bool|string

um_get_user_avatar_url()

um_get_user_avatar_url( $user_id = '',  $size = '96') : bool|string

get user avatar url

Parameters

$user_id
$size

Returns

bool|string

um_invalid_nonce_redirect_url()

um_invalid_nonce_redirect_url(string  $url) : string

Parameters

string $url

Returns

string

um_is_amp()

um_is_amp(bool  $check_theme_support = true) : bool

Check whether the current page is in AMP mode or not.

We need to check for specific functions, as there is no special AMP header.

Parameters

bool $check_theme_support

Whether theme support should be checked. Defaults to true.

Returns

bool

um_is_core_page()

um_is_core_page(string  $page) : bool

Check if we are on a UM Core Page or not

Default um core pages slugs 'user', 'login', 'register', 'members', 'logout', 'account', 'password-reset'

Parameters

string $page

UM core page slug

Returns

bool

um_is_core_post()

um_is_core_post( $post,  $core_page) : bool

Parameters

$post
$core_page

Returns

bool

um_is_core_uri()

um_is_core_uri() : bool

Is core URL

Returns

bool

um_is_file_owner()

um_is_file_owner(string  $url, int|null  $user_id = null, string|bool  $image_path = false) : bool

Check user's file ownership

Parameters

string $url
int|null $user_id
string|bool $image_path

Returns

bool

um_is_meta_value_exists()

um_is_meta_value_exists(string  $key, mixed  $value, mixed  $return_user_id = false) : int

Check if meta_value exists

Parameters

string $key
mixed $value
mixed $return_user_id

Returns

int

um_is_myprofile()

um_is_myprofile() : bool

Check if user is in his profile

Returns

bool

um_is_on_edit_profile()

um_is_on_edit_profile() : bool

boolean for profile edit page

Returns

bool

um_is_predefined_page()

um_is_predefined_page(string  $slug, null|int|\WP_Post  $post = null) : bool

Parameters

string $slug
null|int|\WP_Post $post

Returns

bool

um_is_profile_owner()

um_is_profile_owner( $user_id = false) : bool

Parameters

$user_id

Returns

bool

um_is_selected_filter_value()

um_is_selected_filter_value(mixed  $value) : mixed

Filter profile data value

Parameters

mixed $value

Returns

mixed

um_is_session_started()

um_is_session_started() : bool

Checks if session has been started

Returns

bool

um_is_temp_file()

um_is_temp_file(string  $filename) : bool

Check if file is temporary

Parameters

string $filename

Returns

bool

um_is_temp_image()

um_is_temp_image( $url) : bool|string

Check that temp image is valid

Parameters

$url

Returns

bool|string

um_is_temp_upload()

um_is_temp_upload(string  $url) : bool|string

Check that temp upload is valid

Parameters

string $url

Returns

bool|string

um_is_user_himself()

um_is_user_himself() : bool

boolean check for not same user

Returns

bool

um_js_redirect()

um_js_redirect( $url) : mixed

Parameters

$url

Returns

mixed

um_let_to_num()

um_let_to_num(string  $v) : int|string

Let To Num

Does Size Conversions

Parameters

string $v

Returns

int|string

um_logout_user_links()

um_logout_user_links( $args) : mixed

Adds main links to a logout widget

Parameters

$args

Returns

mixed

um_lostpassword_url()

um_lostpassword_url(string  $lostpassword_url) : string

Change lost password url in UM Login form

Parameters

string $lostpassword_url

Returns

string

um_mail_content_type()

um_mail_content_type( $content_type) : string

Parameters

$content_type

Returns

string

um_maybe_unset_time_limit()

um_maybe_unset_time_limit() : mixed

Maybe set empty time limit

Returns

mixed

um_md_label_birth_date()

um_md_label_birth_date(string  $label, string  $key, string  $data) : string

Change field label from "Birth Date" to "Age" in the member directory.

Parameters

string $label

Field Label.

string $key

Field Key.

string $data

Field data.

Returns

string

um_members()

um_members( $argument) : mixed

Get members to show in directory

Parameters

$argument

Returns

mixed

um_multi_admin_email()

um_multi_admin_email() : array

Get admin emails

Returns

array

um_multisite_urls_support()

um_multisite_urls_support( $dir) : string

Support multisite

Parameters

$dir

Returns

string

um_option_match_callback_view_field()

um_option_match_callback_view_field( $value,  $data) : string

Pair dropdown/multi-select options from a callback function

Parameters

$value
$data

Returns

string

um_post_registration_approved_hook()

um_post_registration_approved_hook(int  $user_id) : mixed

Account automatically approved.

Parameters

int $user_id

Returns

mixed

um_post_registration_checkmail_hook()

um_post_registration_checkmail_hook(int  $user_id) : mixed

Account needs email validation.

Parameters

int $user_id

Returns

mixed

um_post_registration_pending_hook()

um_post_registration_pending_hook(int  $user_id) : mixed

Account needs admin review.

Parameters

int $user_id

Returns

mixed

um_pre_profile_shortcode()

um_pre_profile_shortcode(array  $args) : mixed

Adds profile permissions to view/edit.

Parameters

array $args

Returns

mixed

um_predefined_page_slug_exists()

um_predefined_page_slug_exists(string  $slug) : bool

Parameters

string $slug

Returns

bool

um_pretty_number_formatting()

um_pretty_number_formatting( $count) : string

Formats numbers nicely

Parameters

$count

Returns

string

um_profile()

um_profile( $key) : bool|string

Load profile key

Parameters

$key

Returns

bool|string

um_profile_content_main()

um_profile_content_main(array  $args) : mixed

It renders the content of main profile tab.

Parameters

array $args

Returns

mixed

um_profile_dynamic_meta_desc()

um_profile_dynamic_meta_desc() : mixed

The profile page SEO tags

Returns

mixed

um_profile_field__select_translate()

um_profile_field__select_translate(string  $value, array  $data) : string

Apply textdomain in select/multi-select options

Parameters

string $value
array $data

Returns

string

um_profile_field_filter_hook__()

um_profile_field_filter_hook__( $value,  $data, string  $type = '') : string

Global sanitize

Parameters

$value
$data
string $type

Returns

string

um_profile_field_filter_hook__date()

um_profile_field_filter_hook__date(string  $value, array  $data) : string

Date field.

Parameters

string $value

Date string.

array $data

Field data.

Returns

string

um_profile_field_filter_hook__file()

um_profile_field_filter_hook__file( $value,  $data) : string

File field

Parameters

$value
$data

Returns

string

um_profile_field_filter_hook__googlemap()

um_profile_field_filter_hook__googlemap( $value,  $data) : string

Outputs a google map

Parameters

$value
$data

Returns

string

um_profile_field_filter_hook__image()

um_profile_field_filter_hook__image( $value,  $data) : string

Image field

Parameters

$value
$data

Returns

string

um_profile_field_filter_hook__last_login()

um_profile_field_filter_hook__last_login( $value,  $data) : string

Last login date

Parameters

$value
$data

Returns

string

um_profile_field_filter_hook__oembed()

um_profile_field_filter_hook__oembed(string  $value, array  $data) : string

Outputs a oEmbed field

Parameters

string $value
array $data

Returns

string

um_profile_field_filter_hook__phone()

um_profile_field_filter_hook__phone( $value,  $data) : int|string

Outputs a phone link

Parameters

$value
$data

Returns

int|string

um_profile_field_filter_hook__soundcloud_track()

um_profile_field_filter_hook__soundcloud_track(string  $value, array  $data) : string

Outputs a SoundCloud track

Parameters

string $value
array $data

Returns

string

um_profile_field_filter_hook__spotify()

um_profile_field_filter_hook__spotify( $value,  $data) : bool|string

Outputs a spotify iframe

Parameters

$value
$data

Returns

bool|string

um_profile_field_filter_hook__textarea()

um_profile_field_filter_hook__textarea( $value,  $data) : mixed|string|void

URLs in textarea

Parameters

$value
$data

Returns

mixed|string|void

um_profile_field_filter_hook__time()

um_profile_field_filter_hook__time( $value,  $data) : mixed|string

Time field

Parameters

$value
$data

Returns

mixed|string

um_profile_field_filter_hook__user_registered()

um_profile_field_filter_hook__user_registered( $value,  $data) : bool|int|string

User's registration date

Parameters

$value
$data

Returns

bool|int|string

um_profile_field_filter_hook__viber()

um_profile_field_filter_hook__viber( $value,  $data) : int|string

Outputs a viber link

Parameters

$value
$data

Returns

int|string

um_profile_field_filter_hook__vimeo_video()

um_profile_field_filter_hook__vimeo_video( $value,  $data) : int|string

Outputs a vimeo video

Parameters

$value
$data

Returns

int|string

um_profile_field_filter_hook__whatsapp()

um_profile_field_filter_hook__whatsapp( $value,  $data) : int|string

Outputs a whatsapp link

Parameters

$value
$data

Returns

int|string

um_profile_field_filter_hook__youtube_video()

um_profile_field_filter_hook__youtube_video( $value,  $data) : bool|string

Outputs a youtube video

Parameters

$value
$data

Returns

bool|string

um_profile_field_filter_xss_validation()

um_profile_field_filter_xss_validation(int|string|array  $value, array  $data, string  $type = '') : int|string

Cleaning on XSS injection.

Parameters

int|string|array $value
array $data
string $type

Returns

int|string

um_profile_header()

um_profile_header( $args) : mixed

Profile header

Parameters

$args

Returns

mixed

um_profile_header_cover_area()

um_profile_header_cover_area( $args) : mixed

Profile header cover

Parameters

$args

Returns

mixed

um_profile_id()

um_profile_id() : int

Returns requested User ID or current User ID

Returns

int

um_profile_menu()

um_profile_menu(array  $args) : mixed

Display the available profile tabs

Parameters

array $args

Returns

mixed

um_profile_remove_wpseo()

um_profile_remove_wpseo() : mixed

Remove Yoast from front end for the Profile page

Returns

mixed

um_profile_validate_nonce()

um_profile_validate_nonce(array  $submitted_data) : mixed

Validate nonce when profile form submit.

Parameters

array $submitted_data

Returns

mixed

um_queried_search_value()

um_queried_search_value( $filter, bool  $echo = true) : mixed|string

Check value of queried search in text input

Parameters

$filter
bool $echo

Returns

mixed|string

um_queried_user()

um_queried_user() : mixed

Gets the queried user

Returns

mixed

um_redirect_home()

um_redirect_home(string  $requested_user_id = '', string  $is_my_profile = '') : mixed

Exit and redirect to home

Parameters

string $requested_user_id
string $is_my_profile

Returns

mixed

um_registration_save_files()

um_registration_save_files( $user_id,  $args,  $form_data) : mixed

Saving files to register a new user, if there are fields with files.

Parameters

$user_id
$args
$form_data

Returns

mixed

um_registration_set_profile_full_name()

um_registration_set_profile_full_name( $user_id,  $args) : mixed

Update user Full Name

Parameters

$user_id
$args

Returns

mixed

um_remove_option()

um_remove_option( $option_id) : mixed

Update option value

Please use UM()->options()->remove() instead

Parameters

$option_id

Returns

mixed

um_replace_placeholders()

um_replace_placeholders() : array

Getting replace placeholders array

Returns

array

um_request_user_data()

um_request_user_data() : mixed

Returns

mixed

um_requesting_password_change()

um_requesting_password_change() : bool

Check if a legitimate password change request is in action

Returns

bool

um_requesting_password_reset()

um_requesting_password_reset() : bool

Check if a legitimate password reset request is in action

Returns

bool

um_reset_user()

um_reset_user() : mixed

Clears the user data. If a user is logged in, the user data will be reset to that user's data

Returns

mixed

Examples

You can reset user data by using the following line in your code <?php um_reset_user(); ?>

                                                

um_reset_user_clean()

um_reset_user_clean() : mixed

Clears the user data. You need to fetch a user manually after using this function.

Returns

mixed

Examples

You can reset user data by using the following line in your code <?php um_reset_user_clean(); ?>

                                                

um_restore_default_roles()

um_restore_default_roles( $user_id,  $args,  $to_update) : mixed

Leave roles for User, which are not in the list of update profile (are default WP or 3rd plugins roles)

Parameters

$user_id
$args
$to_update

Returns

mixed

um_safe_redirect()

um_safe_redirect(string  $url) : mixed

UM safe redirect. By default, you can be redirected only to WordPress installation Home URL. Fallback URL is wp-admin URL.

But it can be changed through filters and extended by UM Setting "Allowed hosts for safe redirect (one host per line)" and filter um_wp_safe_redirect_fallback.

Parameters

string $url

redirect URL.

Returns

mixed

um_search_form()

um_search_form() : mixed

Display the search form.

Returns

mixed

um_secure_media_uri()

um_secure_media_uri(string  $url) : string

Set SSL to media URI

Parameters

string $url

Returns

string

um_select_dropdown_dynamic_callback_options()

um_select_dropdown_dynamic_callback_options( $options,  $data) : array

Returns dropdown/multi-select options from a callback function

Parameters

$options
$data

Returns

array

um_select_dropdown_dynamic_options_to_utf8()

um_select_dropdown_dynamic_options_to_utf8(array  $options, array  $data) : array

Filter select dropdown to use UTF-8 encoding

Parameters

array $options
array $data

Returns

array

um_select_if_in_query_params()

um_select_if_in_query_params( $filter,  $val) : mixed

Check whether item in dropdown is selected in query-url

Parameters

$filter
$val

Returns

mixed

um_send_registration_notification()

um_send_registration_notification( $user_id) : mixed

Send notification about registration

Parameters

$user_id

Returns

mixed

um_set_redirect_url()

um_set_redirect_url(string  $url) : string

Set redirect key

Parameters

string $url

Returns

string —

$redirect_key

um_set_requested_user()

um_set_requested_user( $user_id) : mixed

Sets the requested user

Parameters

$user_id

Returns

mixed

um_social_links_icons()

um_social_links_icons( $args) : mixed

Show social links as icons below profile name

Parameters

$args

Returns

mixed

um_store_lastlogin_timestamp()

um_store_lastlogin_timestamp( $user_id) : mixed

Store last login timestamp

Parameters

$user_id

Returns

mixed

um_store_lastlogin_timestamp_()

um_store_lastlogin_timestamp_( $login) : mixed

Parameters

$login

Returns

mixed

um_styling_defaults()

um_styling_defaults( $mode) : array

Get styling defaults

Parameters

$mode

Returns

array

um_submit_account_details()

um_submit_account_details( $args) : mixed

Submit account page changes

Parameters

$args

Returns

mixed

um_submit_account_errors_hook()

um_submit_account_errors_hook(array  $args) : mixed

Validate for errors in account form

Parameters

array $args

Returns

mixed

um_submit_form_data_role_fields()

um_submit_form_data_role_fields(array  $post_form, string  $mode, array  $all_cf_metakeys) : array

Add `role_select` and `role_radio` to the $post_form It is necessary for that if on these fields the conditional logic.

Parameters

array $post_form
string $mode
array $all_cf_metakeys

Returns

array

um_submit_form_data_trim_fields()

um_submit_form_data_trim_fields( $post_form) : mixed

Trim All form POST submitted data

Parameters

$post_form

Returns

mixed

um_submit_form_errors_hook()

um_submit_form_errors_hook(array  $submitted_data, array  $form_data) : mixed

UM login|register|profile form error handling.

Parameters

array $submitted_data
array $form_data

Returns

mixed

um_submit_form_errors_hook_()

um_submit_form_errors_hook_(array  $submitted_data, array  $form_data) : mixed

Error processing hook : standard

Parameters

array $submitted_data
array $form_data

Returns

mixed

um_submit_form_errors_hook__blockedemails()

um_submit_form_errors_hook__blockedemails( $submitted_data) : mixed

Error handling: blocked emails

Parameters

$submitted_data

Returns

mixed

um_submit_form_errors_hook__blockedips()

um_submit_form_errors_hook__blockedips() : mixed

Error handling: blocked IPs.

Returns

mixed

um_submit_form_errors_hook__blockedwords()

um_submit_form_errors_hook__blockedwords(array  $submitted_data, array  $form_data) : mixed

Error handling: blocked words during sign up

Parameters

array $submitted_data
array $form_data

Returns

mixed

um_submit_form_errors_hook__registration()

um_submit_form_errors_hook__registration(array  $submitted_data) : mixed

Validate user password field on registration.

Parameters

array $submitted_data

Returns

mixed

um_submit_form_errors_hook_login()

um_submit_form_errors_hook_login( $submitted_data) : mixed

Error processing hook for login.

Parameters

$submitted_data

Returns

mixed

um_submit_form_errors_hook_logincheck()

um_submit_form_errors_hook_logincheck(array  $submitted_data, array  $form_data) : mixed

Login checks through the frontend login

Parameters

array $submitted_data
array $form_data

Returns

mixed

um_submit_form_login()

um_submit_form_login(array  $submitted_data, array  $form_data) : mixed

Form processing

Parameters

array $submitted_data
array $form_data

Returns

mixed

um_submit_form_profile()

um_submit_form_profile(array  $args, array  $form_data) : mixed

Form processing

Parameters

array $args
array $form_data

Returns

mixed

um_submit_form_register()

um_submit_form_register(array  $args, array  $form_data) : mixed

Registration form submit handler.

Parameters

array $args
array $form_data

Returns

mixed

um_submitting_account_page()

um_submitting_account_page() : bool

boolean for account page editing

Returns

bool

um_time_diff()

um_time_diff( $time1,  $time2) : string

Get core page url

Parameters

$time1
$time2

Returns

string

um_trim_string()

um_trim_string( $s, int  $length = 20) : string

Trim string by char length

Parameters

$s
int $length

Returns

string

um_update_option()

um_update_option( $option_id,  $value) : mixed

Update option value

Please use UM()->options()->update() instead

Parameters

$option_id
$value

Returns

mixed

um_update_profile_full_name()

um_update_profile_full_name( $user_id,  $changes) : mixed

Profile name update

Parameters

$user_id
$changes

Returns

mixed

um_upgrade20beta1_copy_email_template()

um_upgrade20beta1_copy_email_template(string  $template) : bool

Ajax copy template to the theme

Parameters

string $template

Returns

bool

um_upgrade20beta1_email_templates_process()

um_upgrade20beta1_email_templates_process() : mixed

Transferring email templates to new logic

Returns

mixed

um_upgrade20beta1_get_template_file()

um_upgrade20beta1_get_template_file(string  $location, string  $template_name, bool  $html = false) : string

Method returns expected path for template

Parameters

string $location
string $template_name
bool $html

Returns

string

um_upgrade20beta1_insert_content()

um_upgrade20beta1_insert_content(string  $path, string  $content) : mixed

Insert email template content to file

Parameters

string $path

Filepath

string $content

Email template content

Returns

mixed

um_upgrade20beta1_template_in_theme()

um_upgrade20beta1_template_in_theme(string  $template_name, bool  $html = false) : string

Locate a template and return the path for inclusion.

Parameters

string $template_name
bool $html

Returns

string

um_upgrade_balance_field215()

um_upgrade_balance_field215() : mixed

Returns

mixed

um_upgrade_cache2010()

um_upgrade_cache2010() : mixed

Returns

mixed

um_upgrade_choice_callbacks240()

um_upgrade_choice_callbacks240() : mixed

Returns

mixed

um_upgrade_content_restriction20beta1()

um_upgrade_content_restriction20beta1() : mixed

Returns

mixed

um_upgrade_cpt20beta1()

um_upgrade_cpt20beta1() : mixed

Returns

mixed

um_upgrade_email_templates20beta1()

um_upgrade_email_templates20beta1() : mixed

Returns

mixed

um_upgrade_fields2044()

um_upgrade_fields2044() : mixed

Returns

mixed

um_upgrade_get_forums20beta1()

um_upgrade_get_forums20beta1() : mixed

Returns

mixed

um_upgrade_get_products20beta1()

um_upgrade_get_products20beta1() : mixed

Returns

mixed

um_upgrade_get_slug2117()

um_upgrade_get_slug2117( $tab) : mixed

Parameters

$tab

Returns

mixed

um_upgrade_get_users_per_role20beta1()

um_upgrade_get_users_per_role20beta1() : mixed

Returns

mixed

um_upgrade_mc_lists20beta1()

um_upgrade_mc_lists20beta1() : mixed

Returns

mixed

um_upgrade_memberdir210beta1()

um_upgrade_memberdir210beta1() : mixed

Returns

mixed

um_upgrade_menus20beta1()

um_upgrade_menus20beta1() : mixed

Returns

mixed

um_upgrade_metadata210beta1()

um_upgrade_metadata210beta1() : mixed

Returns

mixed

um_upgrade_metadata_per_user213beta3()

um_upgrade_metadata_per_user213beta3() : mixed

Returns

mixed

um_upgrade_metadata_per_user280()

um_upgrade_metadata_per_user280() : mixed

Returns

mixed

um_upgrade_metatable213beta3()

um_upgrade_metatable213beta3() : mixed

Returns

mixed

um_upgrade_phone_fields250()

um_upgrade_phone_fields250() : mixed

Returns

mixed

um_upgrade_profile_tabs2117()

um_upgrade_profile_tabs2117() : mixed

Returns

mixed

um_upgrade_reset_password230()

um_upgrade_reset_password230() : mixed

Returns

mixed

um_upgrade_roles2054()

um_upgrade_roles2054() : mixed

Returns

mixed

um_upgrade_settings20beta1()

um_upgrade_settings20beta1() : mixed

Returns

mixed

um_upgrade_skypeid_fields230()

um_upgrade_skypeid_fields230() : mixed

Returns

mixed

um_upgrade_social_fields260()

um_upgrade_social_fields260() : mixed

Returns

mixed

um_upgrade_social_login20beta1()

um_upgrade_social_login20beta1() : mixed

Returns

mixed

um_upgrade_styles2010()

um_upgrade_styles2010() : mixed

Returns

mixed

um_upgrade_styles20beta1()

um_upgrade_styles20beta1() : mixed

Returns

mixed

um_upgrade_tempfolder2024()

um_upgrade_tempfolder2024() : mixed

Returns

mixed

um_upgrade_update_forum_per_page20beta1()

um_upgrade_update_forum_per_page20beta1() : mixed

Returns

mixed

um_upgrade_update_options280()

um_upgrade_update_options280() : mixed

Returns

mixed

um_upgrade_update_products_per_page20beta1()

um_upgrade_update_products_per_page20beta1() : mixed

Returns

mixed

um_upgrade_update_users_per_page20beta1()

um_upgrade_update_users_per_page20beta1() : mixed

Returns

mixed

um_upgrade_user_roles20beta1()

um_upgrade_user_roles20beta1() : mixed

Returns

mixed

um_upgrade_usermeta_count230()

um_upgrade_usermeta_count230() : mixed

Returns

mixed

um_upgrade_usermeta_count280()

um_upgrade_usermeta_count280() : mixed

Returns

mixed

um_upgrade_usermeta_part230()

um_upgrade_usermeta_part230() : mixed

Returns

mixed

um_upgrade_usermetaquery1339()

um_upgrade_usermetaquery1339() : mixed

Returns

mixed

um_upgrade_users_count213beta3()

um_upgrade_users_count213beta3() : mixed

Returns

mixed

um_user()

um_user( $data, null  $attrs = null) : int|string|array

Parameters

$data
null $attrs

Returns

int|string|array

um_user_edit_profile()

um_user_edit_profile(array  $args, array  $form_data) : mixed

Update user's profile (frontend).

Parameters

array $args
array $form_data

Returns

mixed

um_user_ip()

um_user_ip() : string

Returns

string —

The user's IP address.

Examples

The example below can retrieve the user's IP address <?php $user_ip = um_user_ip(); echo 'User IP address is: ' . $user_ip; // prints the user IP address e.g. 127.0.0.1 ?>

                                                

um_user_last_login()

um_user_last_login(int  $user_id) : string

Get user's last login (time diff)

Parameters

int $user_id

Returns

string

um_user_last_login_date()

um_user_last_login_date( $user_id) : string

Get user's last login time

Parameters

$user_id

Returns

string

um_user_last_login_timestamp()

um_user_last_login_timestamp(int  $user_id) : int|string

Get user's last login timestamp

Parameters

int $user_id

Returns

int|string

um_user_login()

um_user_login(array  $submitted_data) : mixed

Login user process.

Parameters

array $submitted_data

Returns

mixed

um_user_profile_url()

um_user_profile_url(int|bool  $user_id = false) : bool|string

Display a link to profile page

Parameters

int|bool $user_id

Returns

bool|string

um_user_submited_display()

um_user_submited_display(string  $k, string  $title, array  $data = array(), bool  $style = true) : string

Prepare template

Parameters

string $k
string $title
array $data
bool $style

Returns

string

um_user_submitted_registration()

um_user_submitted_registration(bool  $style = false) : null|string

Get submitted user information

Parameters

bool $style

Returns

null|string

um_user_submitted_registration_formatted()

um_user_submitted_registration_formatted(bool  $style = false) : string

Format submitted data for Info preview & Email template

Parameters

bool $style

Returns

string

um_user_uploads_dir()

um_user_uploads_dir() : string

user uploads directory

Returns

string

um_user_uploads_uri()

um_user_uploads_uri() : string

user uploads uri

Returns

string

um_view_label_birth_date()

um_view_label_birth_date(string  $label, string  $data) : string

Change field label from "Birth Date" to "Age" in the profile view.

Parameters

string $label

Field Label.

string $data

Field data.

Returns

string

um_wp_form_errors_hook_ip_test()

um_wp_form_errors_hook_ip_test( $user,  $username,  $password) : mixed

Check for blocked IPs or Email on wp-login.php form

Parameters

$user
$username
$password

Returns

mixed

um_wp_form_errors_hook_logincheck()

um_wp_form_errors_hook_logincheck(\WP_Error|\WP_User  $user) : \WP_Error|\WP_User

Login checks through the WordPress admin login.

Parameters

\WP_Error|\WP_User $user

Returns

\WP_Error|\WP_User

um_wp_safe_redirect_fallback()

um_wp_safe_redirect_fallback(string  $url, string  $status) : string

UM fallback redirect URL

Parameters

string $url

Fallback URL.

string $status

Redirect status.

Returns

string

um_youtube_id_from_url()

um_youtube_id_from_url(string  $url) : bool|string

Get YouTube video ID from URL.

Parameters

string $url

Returns

bool|string