You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/upgrading.md
+79-77
Original file line number
Diff line number
Diff line change
@@ -3,81 +3,83 @@ id: upgrading
3
3
title: Upgrading
4
4
---
5
5
6
-
This is a basic tutorial on how to perform upgrades since version 2.04. This version can automatically update the database from any previous LHC version. Since version 3.30, we require `composer` dependencies to be installed if you are installing from source code.
7
-
8
-
If you are upgrading from an older version to any version 3.30 or higher, you must install composer dependencies.
9
-
```
10
-
cd lhc_web
11
-
composer.phar install
12
-
```
13
-
14
-
If you don't have `composer.phar`, you can download it from https://getcomposer.org/download/.
15
-
16
-
* You can download a version with dependencies included from https://github.com/LiveHelperChat/livehelperchat/releases. Look for the newest file named `*.**v-with-dependencies.tgz`. **PHP version 8.2** is required.
17
-
18
-
This file includes a folder `lib/vendor`, so you don't need to install composer yourself. Just copy it to `lib/vendor`.
19
-
20
-
1. Read the new version announcement article for any possible changes in `settings/settings.ini.php`. If the article does not mention anything, you do not have to do anything.
21
-
2. Go to "System" -> "Update information" and check if LHC finds any differences in the database. If it does, click on "Update database." You may not see differences if your server does not allow making requests to remote URLs.
22
-
* You need to run these commands from the root folder (where `index.php` is located).
23
-
*`php cron.php -s site_admin -c cron/util/update_database` tries to update the database from a remote URL. If this does not work, run:
24
-
*`php cron.php -s site_admin -c cron/util/update_database -p local` after replacing all files.
25
-
3. If you accidentally overwrite files before updating the database, you can:
26
-
1.[Update the database from the local definition](system/command.md#updates-live-helper-chat-database-directly-from-console).
27
-
2. Copy `doc/shell/upgrade.php` to the root folder, the same folder where `index.php` exists.
28
-
1. In your browser, enter `https://example.com/upgrade.php` to update the database directly.
29
-
4. Log out from LHC.
30
-
5.[Download the most recent LHC version](http://livehelperchat.com/article/static/5). Overwrite the following folders: `doc`, `ezcomponents`, `lib`, `modules`, `pos`, `translations`, and `design`. Also, overwrite `index.php` and `cron.php` files with the new version.
31
-
1.https://github.com/remdex/livehelperchat/archive/master.zip - latest master branch zip without composer dependencies.
32
-
2.https://github.com/LiveHelperChat/livehelperchat/releases - latest release with composer dependencies.
33
-
6. Overwrite `composer.json` and `composer.lock` files and run `composer.phar install` or `composer.phar update` command.
34
-
7. Disable [cache in `settings.ini.php`](debug.md#disabling-cache).
35
-
8. Log in to LHC again and go to `"System configuration" -> "Clear Cache"` and click "Clear Cache."
36
-
1. You can also clear the cache by executing this command from the command line: `php cron.php -s site_admin -c cron/util/clear_cache`.
37
-
9. Now you can re-enable the cache in your `settings.ini.php`.
38
-
10. If you still encounter errors, then [Enable debug output](debug.md).
39
-
40
-
If you are updating from any older version, you can follow this pattern, which can also be applied to new versions:
41
-
42
-
1.[Download the most recent LHC version](http://livehelperchat.com/article/static/5). Overwrite the following folders: `doc`, `ezcomponents`, `lib`, `modules`, `pos`, `translations`, and `design`. Also, overwrite `index.php` and `cron.php` files with the new version.
43
-
2. Install composer dependencies as described above. You can just download the most recent `*.**v-with-dependencies.tgz` file from https://github.com/LiveHelperChat/livehelperchat/releases and copy `lhc_web/lib/vendor` to your existing installation. This folder should not exist if you are upgrading from a version older than 4.29.
44
-
3. Copy `doc/shell/upgrade.php` to the root folder of LHC.
45
-
4. In your browser, type `chatfolder/upgrade.php`. It will update the database to the most recent version and clear the cache automatically.
To be able to see `Update information`, the operator must have
71
-
72
-
> 'lhsystem', 'performupdate'.
73
-
74
-
## Troubleshooting Upgrade Issues
75
-
76
-
If you encounter issues during the upgrade process, consider the following steps:
77
-
78
-
1. Ensure that all files have been correctly uploaded and that there are no missing files.
79
-
2. Check the server error logs for any specific error messages that may indicate what went wrong.
80
-
3. Verify that your PHP version meets the requirements specified in the documentation.
81
-
4. If the upgrade fails, you can revert to the previous version by restoring from the backup you created before starting the upgrade.
82
-
5. Consult the community forums or support channels for assistance if you are unable to resolve the issue.
6
+
This guide explains how to upgrade Live Helper Chat (LHC) from version 2.04 onwards. LHC can automatically update the database from any previous version. Since version 3.30, installing from source requires [Composer](https://getcomposer.org/) dependencies.
7
+
8
+
### Prerequisites
9
+
10
+
***Composer:** Required for source installations (version 3.30+).
11
+
* If you don't have it, download `composer.phar` from [https://getcomposer.org/download/](https://getcomposer.org/download/).
12
+
***PHP 8.2 (Recommended):** For the latest version with dependencies, download the `*.v-with-dependencies.tgz` file from [https://github.com/LiveHelperChat/livehelperchat/releases](https://github.com/LiveHelperChat/livehelperchat/releases). This includes the `lib/vendor` folder, so you don't need to install Composer separately. Just extract it to `lib/vendor`.
13
+
14
+
### Upgrade Steps
15
+
16
+
1.**Check Announcement:** Review the new version's announcement for any required changes in `settings/settings.ini.php`.
17
+
2.**Update Database:**
18
+
* Go to "System" -> "Update information" to check for database differences. If found, click "Update database."
19
+
* If the web interface doesn't work, run these commands from the root folder:
20
+
*`php cron.php -s site_admin -c cron/util/update_database` (updates from remote URL)
21
+
* If the above fails, use: `php cron.php -s site_admin -c cron/util/update_database -p local` (after replacing files).
* Run `composer.phar install` or `composer.phar update`.
36
+
6.**Disable Cache:** Disable the cache in `settings.ini.php` (see [debug.md#disabling-cache](debug.md#disabling-cache)).
37
+
7.**Clear Cache:**
38
+
* Log back in and go to "System configuration" -> "Clear Cache" and click "Clear Cache."
39
+
* Alternatively, run `php cron.php -s site_admin -c cron/util/clear_cache` from the command line.
40
+
8.**Re-enable Cache:** Re-enable the cache in `settings.ini.php`.
41
+
9.**Troubleshooting:** If errors persist, [enable debug output](debug.md).
42
+
43
+
### Upgrading from Older Versions
44
+
45
+
For older versions, follow this process:
46
+
47
+
1.**Replace Files:** As in step 4 above.
48
+
2.**Install Composer Dependencies:** As in step 5 above, or download the `*.v-with-dependencies.tgz` file and copy `lhc_web/lib/vendor` to your installation.
49
+
3.**Run Upgrade Script:** Copy `doc/shell/upgrade.php` to the LHC root folder.
50
+
4.**Access Script:** Open `chatfolder/upgrade.php` in your browser to update the database and clear the cache.
51
+
5.**Delete Script:** Remove `upgrade.php` from the root folder.
52
+
53
+
### Important Considerations
54
+
55
+
***Backup:** Always create a backup before upgrading.
0 commit comments