Updater File Changes
Contents
The Automatic Updater is a utility provided by WHMCS which allows you to update your WHMCS installation with minimal interaction.
During the process of updating, WHMCS will update all core files to ensure that WHMCS continues to work correctly with all of the latest updates included.
As part of this process, our default templates and order forms are also updated. If these have been customised, the changes will likely be lost during the update process.
What will be overwritten upon update?
- Language Files (~/whmcs/lang and ~/whmcs/admin/lang)
- Stock Templates (~/whmcs/templates/six and ~/whmcs/templates/orderforms)
- WHMCS-supplied modules (Throughout ~/whmcs/modules/)
- Core WHMCS Files
Why do the templates get updated?
WHMCS is constantly improving. In order to provide these improvements to the Client and Admin areas, adjustments to the Client and Admin templates must be updated to reflect this.
Understanding file override warnings
As a courtesy, WHMCS will perform a scan of your our stock template directories and warn you if it identifies any customisations that will be overwritten during the update. These are provided in a list format to allow you to perform a backup before updating.
When making customisations to the stock templates, WHMCS first recommends that you make a copy of the stock template and customise the copy. We provide more information on this in our Developer Documentation.
Maintaining customisations through updates
To avoid having your customisations overwritten, follow the instructions provided below. This ensures that your customisations are left in-tact after updates.
Languages
To update languages safely, we recommend utilizing our Language Overrides functionality. Language Override files are located in a separate folder which is ignored by the Automatic Updater.
Templates
WHMCS maintains the "Six" template (Client Area), the Blend and V4 templates (Admin Area) and the stock Order Forms. These will be overwritten during the update to ensure they are compatible with any new features implemented. To avoid your customisations being overwritten, WHMCS recommends ensuring that your custom templates are not stored in the "Six" directory or any of the stock Order Form directories.
Instead, ensure each custom template is in it's own, custom-named directory within it's respective directory. You can find more information on correctly creating custom templates in the following places:
Create a custom Client Area Template
Creating a Custom Order Form Template
Modules
WHMCS will update all modules which are currently maintained. You should ensure any custom modules have unique filenames and have not overwritten a WHMCS-maintained module. As long as the module name is unique, WHMCS will ignore these during the update process.
WHOIS and Additional Domain Fields
During an update, WHMCS will also update the core dist.whois.json and dist.additionalfields.php files. To avoid your customisations being overwritten, it's important that your changes are stored in the appropriate override files.
Customising Additional Domain Fields
Core WHMCS Files
Some WHMCS files are provided in an "Open-Source" format to allow for customisations. For example, /aff.php. At this time, there is no way of ensuring these files are not overwritten in the event of an update. For this reason, you should ensure any customisations of WHMCS files have been backed up. After the update has been completed, you can then analyze these files and merge your customisations back in to them if required. You may find the DiffChecker website to be a useful tool in achieving this.