Fixing Outdated Ultimate Member Templates
Template Updates and Changes
When a new version of Ultimate Member is released, the plugin updates its default templates. You must keep your custom templates up to date depending on the most recently changed version in template markup.
See an example below from the ultimate-member/templates/login.php file. We have the @version x.x.x in the template file comment to specify when the template was changed.
NOTE: This functionality is only available if your Ultimate Member plugin version is 2.6.2. or higher.
- Most theme authors modify their themes in a timely manner, so you simply need to update your theme to obtain updated templates.
- If you modified the templates or are using a child theme, you have to update them yourself.
How to update outdated templates
We need to determine which templates to update, create a backup of the previous templates, and then restore any customization.
- Navigate to wp-admin > Ultimate Member > Settings > Override templates. Here you can find a list of templates that have been overridden by your theme or child theme, as well as a warning notice that they need to be changed. In the Status section, for example, if the theme version is out of date, a red X will appear, and if it is up to date, a green check mark will appear.
If you want to check and compare the differences between the customized template and the current UM template files, below are some applications you can download to your PC and online services you may use.
Example: Comparison of "login.php file version 2.6.1 vs. version 2.0.4 ". View full comparison here.
- Save a backup of the outdated template.
- Copy the default template file from wp-content/plugins/ultimate-member/templates/[path-to-the-template] and paste it into your theme to a proper subfolder. See the Templates Map here.
- Open the template you pasted into the theme folder with a text editor of choice, such as Sublime, Visual Code, Notepad++ and replicate changes that you made to the previous template in your new updated template file.
- Once template files are updated go back to the Override templates tool and click the Re-check templates button.
NOTE: We are not able to provide any support when it comes to customizing templates. We understand how time-consuming it may be but occasionally breaking backward compatibility is necessary.
Warning: We highly recommend to use child-theme for public free or pro themes. Do not edit template files within the core plugin itself, as they are overwritten during the upgrade process and any customizations will be lost. We recommend using a child-theme, which has no dependencies with the official themes repo, so your custom files cannot be rewritten after a theme upgrade.