Upgrade to a New Version
Check Your Current Version
Verify your current version by logging in as an admin at example.com/en-us/admin
. Your version number is displayed on the dashboard. Alternatively, check the version.txt
file in the provided zip file.
Upgrade to Version 2
If you are running version 1.x.x, follow the steps here to upgrade to Reward Loyalty v2.
Backup First
Before upgrading, back up your system. This allows you to revert to the previous state if errors occur. In Laravel-based systems, updates involving third-party libraries might lead to a 500 error.
To backup, duplicate the web root folder. In case of errors, delete the updated web root and rename the backup to the original folder name.
See "reinstall the script" to find out where all the user data is stored in case you need it.
Upgrade Procedure
-
Locate Upgrade Files: In your downloaded zip, navigate to the
upgrade
folder. Find zip files namedupgrade-x.x.x-to-[version].zip
. - Select Correct File: Use the file that matches your current version. If your version is older than those in the zip, choose the closest higher version.
- Extract and Replace: Unzip the selected file and replace your script's existing files with these new ones.
Sequential Upgrade
Upgrades must be sequential:
Scenario A: You are currently using version 1.5.0
of the script:
- Start by unzipping
upgrade-1.x.x-to-1.6.0.zip
- Next, unzip
upgrade-1.6.x-to-1.8.0.zip
- Continue this pattern until you've applied all the upgrade files up to the latest version.
Scenario B: Your current version is 1.16.1
:
- Begin with
upgrade-1.15.x-to-1.20.0.zip
- You can skip the earlier files, as they're for versions older than yours.
Scenario C: You are at version 1.8.5
:
- Start with
upgrade-1.8.x-to-1.15.0.zip
- Then, unzip
upgrade-1.15.x-to-1.20.0.zip
- Continue in order till the latest version.
If sequence errors occur, restart with the correct order or re-upload the entire public_html
folder without deleting any files.
Database Update
-
Admin Login: After file updates, log in as admin at
example.com/en-us/admin
. - Update Prompt: If needed, a database update prompt like "An update is required for your database. Click here to apply the update." will appear. Click it to execute updates.
Ensure database synchronization post-upgrade to avoid functional issues.
Troubleshooting After Upgrade
If you can’t access the script after the upgrade:
-
Refresh Autoload Map: Most issues can be resolved by refreshing the autoload class map. Run the following in SSH CLI:
$ cd /path/to/your/installation $ composer dump-autoload
-
Further Steps: Persisting issues? Try these commands:
$ cd /path/to/your/installation $ rm -rf vendor composer.lock $ composer update
If you’re not sure how to use the command line in your hosting account, contact your hosting provider for assistance.