Then add this code to a file in wp-content/mu-plugins/ or to your theme's functions.php
https://gist.github.com/wp-user-manager/4a31e4f085b8f8a6fed3a1c79a0fd69d
---
# Allow administrators to view profiles, when members cannot
URL: https://wpusermanager.com/article/202-allow-administrators-to-view-profiles-when-members-cannot/
Last updated: 2019-10-16
If you have disabled the 'Allow members to view profiles' setting but you still want site administrators to be able to view profiles, then add this code to an mu-plugin or your theme's functions.php:
https://gist.github.com/wp-user-manager/04738893f2c5c6a75044696c63c8bf75
---
# Automatically resize uploads for avatars
URL: https://wpusermanager.com/article/201-automatically-resize-uploads-for-avatars/
Last updated: 2019-10-15
If you want to ensure all avatar mages uploaded are resized to a specific file size (width and height), then add this code to an mu-plugin file or your functions.php file:
https://gist.github.com/polevaultweb/caefbec5eaaa9e5f032427adb27251a2
---
# Removing the cover photo from the profile
URL: https://wpusermanager.com/article/212-removing-the-cover-photo-from-the-profile/
Last updated: 2023-02-18
If you don't want to display the user's cover photo on their profile page then you will need to customize the profiles/cover.php template.
First of all, you should learn how the template system works. Read more information in this article
Your custom cover.php template should look like this:
https://gist.github.com/wp-user-manager/b68f43658b51d2d899ebdcb8bda92303
---
# Change the profile settings header text on the Account page
URL: https://wpusermanager.com/article/215-change-the-profile-settings-header-text-on-the-account-page/
Last updated: 2019-11-06
Add the following to an mu-plugin or your theme's functions.php file:
https://gist.github.com/wp-user-manager/f6fca7fd28bd80ec8c7b7b3c314fabba Update the text at line 4 to change it to your desired header.
---
# Showing a logout link into a theme
URL: https://wpusermanager.com/article/167-showing-a-logout-link-into-a-theme/
Last updated: 2019-09-05
Showing a logout url into a theme can be done with the [wp\_logout\_url()](https://codex.wordpress.org/Function_Reference/wp_logout_url) function. This function can be placed anywhere into your theme files and accepts a custom url as optional parameter.
If the redirect parameter is not used, users will automatically be redirected to the page you've selected into the settings panel.
Example usage: logout and redirect to current page.
```
```
Example usage: logout and redirect to another page by ID
```
```
---
# Disable the "remember me" option into the login form
URL: https://wpusermanager.com/article/166-disable-the-remember-me-option-into-the-login-form/
Last updated: 2019-09-02
When developing with WP User Manager, you might want to disable and remove the "remember me" checkbox from the login form. In order to achieve this, you can use the `wpum_login_shortcode_args` filter.
You can add the following snippet at the bottom of your theme's functions.php file.
https://gist.github.com/alessandrotesoro/661f2e2e1bfcb09df652d8bd7c68588e
---
# How to hide the field group title and description from profile page
URL: https://wpusermanager.com/article/150-how-to-hide-the-field-group-title-and-description-from-profile-page/
Last updated: 2023-02-17
The user public profile page will display the field groups title and description. If for any reason you might want to remove them from displaying, follow these instructions.
Before following these instructions make sure you are comfortable and understand how to customize the WPUM template files. Read more here
### Remove the title and description
1. Retrieve the file about.php from the "templates/profile" folder of the plugin.
2. Copy and paste the file into your theme's wpum folder in order to modify it. Please read the above links for more information.
3. Open the about.php file with your favorite code editor and remove the following code:
```
```
Save the file. The description and group title have now been removed.
---
# Set maximum upload size for avatars and cover images
URL: https://wpusermanager.com/article/146-set-maximum-upload-size-for-avatars/
Last updated: 2019-12-03
It is recommended that you limit the size of the images that your members are able to upload onto your website. In this way you can prevent your users from wasting disk space on your server.
In order to set a size limit, add the following line to your theme's functions.php file, or to your wp-config.php file.
```
// Set the avatar image max size
define( 'WPUM_MAX_AVATAR_SIZE', 10240 );
// Set the cover image max size
define( 'WPUM_MAX_COVER_SIZE', 5242880 );
```
The above example will set the maximum file size for avatars to 10kb and cover images to5MB. The WPUM\_MAX\_AVATAR\_SIZE and WPUM\_MAX\_COVER\_SIZE constants only accept bytes as a value.
Sizes examples:
50kb = 51200
100kb = 102400
1mb = 1048576
You can use a website like this to help you calculate the any size you want
---
# How to disable the built-in custom menu controller
URL: https://wpusermanager.com/article/137-how-to-disable-the-built-in-custom-menu-controller/
Last updated: 2019-10-09
WPUM comes with a built-in custom menu visibility options. It's possible that sometimes conflicts with other menus related plugins would make WPUM's settings disappear or the third party plugin's settings disappear within your WordPress admin panel menu editor.
If you wish to disable the built-in WPUM menu visibility options, you can add the following code to your website's wp-config.php file. You can access the file via ftp through your host.
```
define('WPUM_DISABLE_MENUS_CONTROLLER', true);
```
---
# How to add email confirmation at registration
URL: https://wpusermanager.com/article/136-how-to-add-email-confirmation-at-registration/
Last updated: 2019-09-02
The WP User Manager plugin has many filters that allows developers to extend the plugin and add new fields. In some cases you might want to add an email confirmation field so that user can type the email twice to make sure it's correct.
The ` wpum_get_registration_fields` filter allows developers to introduce new fields into the registration form. Once the field has been added, you can use the `submit_wpum_form_validate_fields` filter to add new validation rules. The new validation rule is needed so that you can actually verify that both emails are the same.
Here's the full code:
https://gist.github.com/alessandrotesoro/22de8830219dec313878ce243db0f62a Within the snippets you can feel free to modify the label, description and even the validation error.
---
# Create a new tab on the Profile page
URL: https://wpusermanager.com/article/223-create-a-new-tab-on-the-profile-page/
Last updated: 2023-03-23
If you are trying to add new content to a user's profile page, you can add a new tab to the profile, and render your custom content using the following code.
The code should be added to an mu-plugin file, eg. wp-content/mu-plugins/wpum.php
https://gist.github.com/wp-user-manager/8f6a28199450cca0a3a036a41bb09634
---
# How to move the role dropdown to the top of the form
URL: https://wpusermanager.com/article/218-move-role-dropdown-to-top-of-form/
Last updated: 2019-12-19
If you want to move the role dropdown to the top of the registration form, add this code to an wp-content/mu-plugins/ file (eg. wp-content/mu-plugins/wpum.php) or your theme's functions.php file:
https://gist.github.com/wp-user-manager/750edafae72fd5a0b7022b58a6df3cfd
---
# How to add an external link to the Profile page tabs
URL: https://wpusermanager.com/article/222-how-to-add-an-external-link-to-the-profile-page-tabs/
Last updated: 2020-02-02
If you want to add a new tab to the Profile page that adds an external link, add the following code to a file in wp-content/mu-plugins (eg. wpum.php) or your theme's functions.php file:
https://gist.github.com/wp-user-manager/255daeb154155916fa0b6d0b73a8fc9d (Requires WP User Manager version 2.2.3 or higher)
---
# How to change the post type of the Posts displayed on the Profile
URL: https://wpusermanager.com/article/235-how-to-change-the-post-type-of-the-posts-displayed-on-the-profile/
Last updated: 2020-09-16
Not every site will have users creating posts, instead they might be creating items in a custom post type, and you want to show those on users profile pages.
You can change the 'Posts' tab to change the label and use a different post type to display the items:
https://gist.github.com/wp-user-manager/34405d267085b8df038c0b3ca94cf0e3
---
# Remove the user nickname from the Display name dropdown in the Account page
URL: https://wpusermanager.com/article/204-remove-the-user-nickname-from-the-display-name-dropdown-in-the-account-page/
Last updated: 2019-10-25
If you want to remove the user nickname selection option in the 'Display name' dropdown on the Account page (or any other option), add this code to an wp-content/mu-plugins/ file (eg. wp-content/mu-plugins/wpum.php) or your theme's functions.php file:
https://gist.github.com/wp-user-manager/86bba2f34c0f867da3c88f5228372d33
---
# Redirect the login and register pages for logged in users to the account page
URL: https://wpusermanager.com/article/200-redirect-the-login-register-pages-for-logged-in-users-to-account-page/
Last updated: 2019-10-23
When logged in users visit the login or register page they will see a page that says "You are currently logged in as..." with some helpful links. This template can be [customised](https://wpusermanager.com/article/121-templates-customization), but for some these pages aren't necessary.
To redirect logged in users who visit the login or register pages to the account page, add this code to your theme's functions.php or to an mu-plugin file inside `wp-content/mu-plugins`:
https://gist.github.com/wp-user-manager/24be5c9c96d4d7e3b7dbb8a01e6d3234
---
# User Verification WP-CLI Commands
URL: https://wpusermanager.com/article/232-wp-cli-commands/
Last updated: 2020-06-14
Currently the User Verification plugin has the following custom [WP-CLI](https://developer.wordpress.org/cli/commands/) commands:
`wp wpum revoke-users` - Revoke approved users, changing their status back to pending.
eg. `wp wpum revoke-users --users=1,2,4`
`wp wpum resend-verification-email` - Resend verification email to pending users
---
# wpum_get_core_page_id()
URL: https://wpusermanager.com/article/168-wpumgetcorepageid/
Last updated: 2023-02-28
Retrieves the page ID number of the core pages used by the theme and selected into the admin panel. Information about each page can be found here
Supported parameters:
- $name - supported options: login, register, password, account, profile
**Example usage:**
Get login page ID:
```
$login_page_id = wpum_get_core_page_id( 'login' );
```
Get registration page ID:
```
$registration_page_id = wpum_get_core_page_id( 'register' );
```
---
# Elementor Widgets
URL: https://wpusermanager.com/article/342-elementor-widgets/
Last updated: 2023-03-13
To use Elementor with WP User Manager before version 2.9 you would have needed to use the WPUM shortcodes when building pages with Elementor. Now there are dedicated Elementor widgets for the WPUM shortcodes:

For example, this is using the Login Form shortcode:

---
# Registering new template locations
URL: https://wpusermanager.com/article/230-registering-new-template-locations/
Last updated: 2020-06-02
By default, WP User Manager will look in your theme directory in the `wpum` folder for any templates you have customized, that will overrdie the default WP User Manager ones.
However, if you want to store your templates elsewhere, like in a plugin or mu-plugin, you can tell WP User Manager where they located using this code:
https://gist.github.com/wp-user-manager/57b18f07263f4a32e6df97c7bd4041d0
---
# Customizing the email design
URL: https://wpusermanager.com/article/124-customizing-the-email-design/
Last updated: 2023-02-17
When building a site or theme with WP User Manager, you will want to customize the email design. Luckily WPUM allows you to do this and it's very easy to do.
First of all, you should learn how the template system works. Read more information in this article:
Now that you learned how to override the templates, we will have a look at which template files are used by the emails.
By default, all emails sent through WPUM will use the template selected by the admin in *Users > Settings > Emails.* If you wish to modify these template files in any way, simply copy the *emails* folder to a folder called *wpum* in your theme and then modify them.
Templates Usage:
----------------
- [emails](https://github.com/wpusermanager/wp-user-manager/tree/master/templates/emails)/**header.php:** used when the "no template, plain text only" option is selected into the admin panel.
- [emails](https://github.com/wpusermanager/wp-user-manager/tree/master/templates/emails)/**body.php:** used when the "no template, plain text only" option is selected into the admin panel.
- [emails](https://github.com/wpusermanager/wp-user-manager/tree/master/templates/emails)/**footer.php:** used when the "no template, plain text only" option is selected into the admin panel.
- [emails](https://github.com/wpusermanager/wp-user-manager/tree/master/templates/emails)/**header-default.php:** used when the "default template" option is selected into the admin panel.
- [emails](https://github.com/wpusermanager/wp-user-manager/tree/master/templates/emails)/**body-default.php:** used when the "default template" option is selected into the admin panel.
- [emails](https://github.com/wpusermanager/wp-user-manager/tree/master/templates/emails)/**footer-default.php:** used when the "default template" option is selected into the admin panel.
---
# Customizing the user directory template
URL: https://wpusermanager.com/article/123-customizing-the-user-directory-template/
Last updated: 2023-02-17
A lot of times when building a site or theme with WP User Manager, you will want to customize the template of the user directory. Luckily WPUM allows you to do this and it's very easy to do.
First of all, you should learn how the template system works. Read more information in this article:
Now that you learned how to override the templates, we will have a look at which templates are used by the user directory.
Main Directory Template
-----------------------
templates/ **directory.php**
The directory.php file, is the template file responsible to handle the display of a directory. **You should only modify the code between this line**
```
```
and this line
```
```
Please do not remove calls to the do\_action() function within this file. The plugin itself and the addons will make use of these actions, removing those lines will break the plugin and it's addons.
Single User Template
--------------------
/directory/ **single-user.php**
The main directory template file loads an additional file called "single-user". This file is used to display the detail of each individual user found within the directory.
Top Bar Template
----------------
directory/ **top-bar.php**
Each directory has the ability to display a "sort" field and an "amount modifier" field. It also displays the total amount of users that have been found for that directory.
---
# Example template customization
URL: https://wpusermanager.com/article/122-example-template-customization/
Last updated: 2019-09-02
Now that you've learned how to customize the templates and where to find them, let's make a small test modification. In this example we will add some custom text above the registration form.
Remember this is just a very simple example, custom text can obviously be added through the WordPress page editor.
1 Navigate to the wp-content/plugins/wp-user-manager/templates/ folder on your server. ( You should connect via FTP or any other way you use to access your files ) 2 You will notice files and sub folders. The registration form template file can be found into the subfolder "**forms**". 3 Open the subfolder "**forms**" and copy the file **registration-form.php** 4 Now navigate to your theme's folder - for example **wp-content/themes/twentyfifteen** 5 Create a new folder called "**wpum**" if it does not exist. 6 Because the **registration-form.php** file was into a subfolder called "**forms**" - you must create a new folder called "**forms**" into your "**wpum**" folder. 7 Now paste the registration-form.php file that you have previously copied. Your structure should now look like this
8 Open up the file with your favorite code editor and add or modify the content of the file. In this example i've simply added a custom phrase at the top of the form:
Save the file and visit your registration page ( remember the registration form is visible only when NOT logged in ) and if you've done everything correctly, you will see your custom phrase on top of the form.

---
# Templates customization
URL: https://wpusermanager.com/article/121-templates-customization/
Last updated: 2019-09-02
WP User Manager is designed to work right out of the box with most WordPress themes. It does this by using a template hierarchy system in the same way WordPress does. Furthermore the plugin comes with a very minimalistic layout so that it can easily be adapted/modified to your theme.
WPUM allows you to make any kind of modifications to the template files of the plugin. In this way you can make minor or major modifications to any template used by WPUM.
### How files are loaded
WP User Manager uses a fallback template system, it works the same way the WordPress theme files do.
1. If a child theme is installed on your website, WPUM will look for it's templates into your child theme first.
2. If a child theme is installed but does not have any WPUM templates, it will search into your parent theme.
3. If no child theme is installed, WPUM will search into your main theme only.
4. If no templates are found into your theme, WPUM will use it's default templates that come with the plugin.
### How to customize the templates
In order to customize the templates of the plugin you need to create a new folder called "wpum" (without the quotes) into your custom theme's folder. Example, if your theme is "Twenty Fifteen", your theme's folder will be in
```
wp-content/themes/twentyfifteen
```
Now create a new folder called "wpum" into the "twentyfifteen" folder. See screenshot below:

You can now copy any of the template files of WP User Manager, into the "wpum" folder of your theme. The template files of the plugin can be found in folder
```
wp-content/plugins/wp-user-manager/templates/
```
on your server.
You must follow the same file/folder names and placement into your theme's folder.
### What you should never do
You shouldn't under any circumstance remove any call to the do\_action() WP function within the template files. If you do, you will break addons functionalities in some cases.
---
# Customize the user profiles
URL: https://wpusermanager.com/article/105-customize-the-user-profiles/
Last updated: 2023-02-17
A lot of times when building a site or theme with WP User Manager, you will want to customize the users public profile page. Luckily WPUM allows you to do this and it's very easy to do.
First of all, you should learn how the template system works. Read more information in this article
Now that you learned how to override the templates, we will have a look at which templates are used by the profile page.
Templates Usage:
----------------
#### profile.php
Is the template file that displays all the content within the profiles pages.
#### profiles/about.php
This file loads the content of the "about" tab within the profiles page. This contains the list of all the user's fields.
#### profiles/comments.php
Displays a list of the comments submitted by the user.
#### profiles/cover.php
Displays the cover pictures of the user.
#### profiles/intro.php
Displays the user's avatar, name and description.
#### profiles/navigation.php
Displays the links to the tabs of the profile page.
#### profiles/posts.php
Displays the posts submitted by the user.