Enable Multiple Versions of PHP on an InterWorx Server
Naturally, you can use the version of PHP that ships with your operating system if you wish, but many popular PHP scripts now require newer versions of PHP and won't work with PHP 5.3 or 5.4. However, if you were to update your main version of PHP to 7.3 you may run into issues where some scripts may only work with PHP 7.1 or 7.2. So what can you do? You can install multiple versions of PHP and let each user account use whatever version of PHP they need. Thankfully InterWorx makes it easy to offer exactly that!
To convert your server to use multiple versions of PHP, log into NodeWorx as an administrative user and then follow these steps:
- Navigate to the Web Server item, which can be found under the System Services section of the sidebar.
- Scroll down to Multiple PHP Versions. Click on the Enable button in that area to activate this feature.
- When the process is complete, a number of new settings will appear in this area.
- Now you can click the checkboxes next to each version of PHP you want to offer to users on this server. You can also click the check all or check none buttons to quickly select or deselect all versions of PHP.
Once you've chosen the versions of PHP you want to offer, click the Update button and InterWorx will start the installation in the background. During this time a spinning indeterminate progress indicator will appear next to the Update button.
You shouldn't try to do anything else on this page until the installation process is complete. It will take some time, especially if you choose to install all available versions of PHP.
- Now you need to select the default version of PHP. You can change the default version at any time, by selecting one from the Default PHP Version drop-down list and then clicking the Update button.