How To Host And Install PHP Script On Cpanel | Example: PHP Script From CodeCanyon

Install PHP Script on Cpanel

In this post, I will show you how to host and install a PHP script in Cpanel.

For this, I will take as an example a PHP script that I bought from CodeCanyon, to build my website.

The PHP Script We Will Use As An Example To Host And Install PHP Script On Cpanel

The website offers several small SEO tools like the plagiarism checker, Alexa ranking, Whois checker and so on.

The script contains in total, 50 small SEO tools. I haven’t activated them all yet.

Despite the fact that 2 or 3 of them didn’t work, i think it’s still a good script overall.

My idea for this website is to start with this version and see how it evolves, then add some more advanced tools later.

If you like to see this in action, you can check this video here:

How To Find The PHP Script In CodeCanyon

The CodeCanyon marketplace contains many kinds of digital products like PHP scripts, WordPress, eCommerce, Javascript and so on.

In the PHP script category, if you do search for “SAAS” keyword for example you will find many scripts. You should check this list if you’re thinking to start small SAAS business.

To find the script that we will install in this post, just do research with “SEO tools” keyword.

code canyon seo tools php script

The script that we are going to install is the one shown in the image above. It has good reviews as you can see.

Once you bought it, you can go in your profile account and download the zipped file in the download section.

General Principle Of Installing a PHP Script

Before, we start installing the script. I want to clarify the general steps to install a PHP script in Cpanel.

First, we will upload and unzip the file that we downloaded from Codecanyon.

Secondly, we will create a database and a user and give him access to this database.

Then there are generally two options:

  • Either the editor provides an install script, in this case, we run it. And we fill in the information concerning the database, the user, the license then we click some next buttons.
  • Otherwise, the second option is to fill in the information in a config file indicated in the installation documentation. In this second option, there is generally an SQL file provided that you have to run to create the database and feed it.

Let’s Move On Now To Practice

Step1: explore the installation folder

First of all, we will explore the content of the installation folder downloaded from CodeCanyon.

In the case of this script, you will notice that there is a documentation folder. I double click on the index.htm file to open the doc file in my browser.

The installation steps described for this script are exactly those, which we have just seen. Here the editor provides an install script which corresponds to option 1 we juste seen before.

Step2: upload the script in Cpanel

The folder to upload to the server is named upload for this script. I first zip it locally. Then I upload it to the server.

Then in Cpanel, I click on “File Manager”. I click on upload and I choose the zipped file from my laptop.

Now that the file is completely uploaded to the server. I unzip it, then I migrate all its content to the root of the website.

Finally, i delete the upload folder which is empty.

Step3: Create the database

The next step is to create the database. For that, in Cpanel, I scroll down to the database section, and I click on MySQL databases.

I give a name to it and I click create database.

Step4: Create a database user

Then, I scroll down to the create user section to create a user.

I enter a name. Then, I click on password generator to create the password automatically.

I copy the password before I use. Then I click create user.

Step5: Give the user rights to the created database

The next step is to give the rights to the user that i had just created to my database.

This happens in the section “add a user to the database”.

By the way, we are still in the page ” mysql databases”.

I choose the user and database in the dropdown lists and click Add button. Then I check “all privileges”, and I click on make changes.

Step6: Run the installation script

Now, I run the installation script, by visiting the index.php page in my Web browser. The url is your domain/index.php as mentionned in installation documentation.

It starts by checking the setting of the server. It’s ok for me. I just click on continue.

Then, I fill in the requested information: For the server, I enter localhost, then i fill in the name of the database, the user name and password, as well as the certificate provided when i bought the script.

For the names of database and user, you have to enter the full names which includes the prefix added automatically when they are created.

That’s all you click on submit and you’re done.

In case you come across a script with option 2: the installation document will indicate a file to edit and modify. And you will also need to run an SQL file to create the database, by going to PHPMyAdmin, then, selecting the database. Click then on SQL, paste the SQL queries and then click on execute button.

Leave a Comment

Your email address will not be published. Required fields are marked *