Have you ever had a website with a different PHP version? Of course you have. For example, website A uses PHP version 5.6 and website B must be deployed using PHP version 7.2. Well, this is quite a hassle when you only have 1 hosting. In the past, 1 hosting could only support 1 PHP version. But now you can create multiphp on all KincaiHosting hosting, you know! Want to know how to create multiphp on hosting, let's follow the following guide.
What is MultiPHP?
MultiPHP is a feature where users can have several PHP versions on hosting. Quoted from cPanel , MultiPHP is designed to meet the needs of various customers.
In the past, hosting could only be singlePHP. If you only have 1 hosting, it means you can only use 1 PHP version. So, for example, you have several subdomains and on that subdomain there is a project that must use a different PHP version, you need another hosting order. Because 1 hosting can only have 1 PHP version.
Now, all hosting packages at KincaiHosting can be multiPHP, you know! With just 1 hosting, you can use several versions of cPanel for both subdomains and addon domains. For example, suppose you have 1 hosting. And you have to upload several websites with the following conditions,
- Using subdomain multi1.namadomain.com
- Using PHP version 5.6
- Using subdomain multi2.namadomain.com
- Using PHP version 7.2
Preparation Stage of Making MultiPHP
- Make sure you already have hosting at KincaiHosting. For those who don't have it, please order cheap hosting or please use a domain-saving and hosting package.
- Make sure you have created a subdomain or addon domain for a website with a different PHP version. To create a subdomain, please follow How to Create Subdomains on cPanel Hosting.
- Know how to use File Manager. To make multiPHP on hosting, you must know about the file manager and how to do file editing in the file manager .
How to Create MultiPHP on Hosting
As for how to create multiphp on hosting, namely,
1. Login cPanel Hosting
The first step you have to do is login to cPanel. CPanel login can be via https: // domainname / cpanel, according to the email sent from KincaiHosting regarding Hosting Account Information. For those of you who don't know how to log in to cPanel, please read the Easy Way to Login cPanel Hosting.
2. Choose File Manager
Then, you will be directed to KincaiHosting's cPanel dashboard. In the search field, please write "file manager". Then click the menu.
3. Go to the Subdomain Folder or Addon Domain
Now it's time to enter the website file that you uploaded. You can upload website files on your hosting using a subdomain or addon domain. In this guide, for example using a subdomain.
Note : If this website is in the main domain then please go to public_html. If the website file is placed on a subdomain, then please enter the subdomain folder.
4. Creating MultiPHP on Hosting
Here is a simulation of how to create multiphp on hosting.
a. Website A
Please enter the subdomain folder. For example multi1.namadomain.com. And you are using PHP version 5.6. Then add the following code in the .htaccess file.
application/x-httpd-alt-php56___lsphp is a PHP 5.6 list handler
b. Website B
Please enter the subdomain folder. For example multi2.namadomain.com. And you are using PHP version 7.2. Then add the following code in the .htaccess file.
application/x-httpd-alt-php72___lsphp is a PHP 7.2 version list handler
Here are some list of handlers that can be used for several versions of PHP.
If so, please click
5. MultiPHP Successfully Created!
Yeay! MultiPHP created successfully! Now you can upload websites with different php versions on hosting. You can use the php version that supports website themes and plugins. So, you will avoid some website errors. To check your website, you can create an info.php file on a subdomain. Then please fill in the following script:
The following script functions to display the PHP version used on the website. The following screen will appear automatically.
How to create multiphp on hosting is very easy. For those of you who have a website with many php versions, you can follow this guide. For those of you who have a website on only one domain or only use one PHP version on hosting, there is no need to use this method. You can change the php version in the php option according to the guide on How to Change the PHP Version on cPanel Hosting . If you have any questions, please contact the Support Team!