# Shared Hosting / cPanel

This section will guide you **step by step** through the process of deploying **Evaluator** on a shared hosting service using **cPanel**.

### Step 1 - Upload the Files

1. **Download** the project folder `evaluator.zip` from **CodeCanyon**.
   1. Extract the `evaluator.zip`
   2. As You can see the folder structure like below,

      ```
      Evaluator
      ├── project.zip
      ├── README.pdf
      ```
2. **Log in** to your **cPanel** account.
3. Go to your hosting’s **root directory**.
   * For most shared hosting services, this is usually the **public\_html** folder (The exact folder name may vary depending on your hosting provider).
4. **Upload** the `project.zip` file to this folder.

{% hint style="success" %}
Direct uploading through cPanel can be time consuming and error-prone. We recommend using a free FTP client such as **FileZilla** for a faster and more reliable upload process.
{% endhint %}

5. **Unzip** the `project.zip` file in your hosting directory.

### Step 2 - Setting up project details in `.env`

{% hint style="warning" %}
Before diving into the section below, we strongly recommend referring to the [.env](/evaluator/miscellaneous/.env.md) section of this document.
{% endhint %}

1. **Open the `.env` file.**
2. In the top section, change project details as below.
3. If values contain spaces, make sure to wrap them inside **double quotes.**

```
APP_NAME=Laravel        -> Replace this with the name of your site
APP_ENV=production
APP_KEY=
APP_DEBUG=false
APP_URL=http://localhost  -> Change this to your project domain
```

**APP\_NAME**\
This must be the name of your site/company;

* Example: if your site name is *Smart Evaluator*, the value must be set as:

```
APP_NAME="Smart Evaluator"
```

**APP\_URL (!important)**\
This must be the domain of your site;

* Example: if your site domain is `https://evaluator.org`, the value must be set as:

```
APP_URL="https://evaluator.org"
```

***

### Step 3 - Create and setup MySQL Database

1. In your hosting control panel, go to **MySQL Databases**.
2. Create a new database (e.g. `evaluator_db`).
3. Create a new database user and password.

{% hint style="danger" %}
&#x20;Don't use **#** in database password string and make sure to use a strong password. Keep these details for later use.
{% endhint %}

4. Assign the user to the database with **All Privileges**.
   1. &#x20;In cPanel you can do this by navigating to the "Manage User Privileges" section, choose the privileges you want to assign to the user for the  specific database, then click on "Make Changes". Give user Full Privilege.

### **Step 4 - Add database details :**

Add manually database details via **.env** file, follow these steps:

* Locate the `.env` File: The `.env` file is located in the root directory of your Laravel project. Use a text editor to open the file.
* Find the Database Configuration Section: Look for the section in the `.env` file that contains the database configuration variables. It typically starts with `DB_`.
* Set Database Connection Details: Update the values of the following variables to match your database configuration:

```
DB_CONNECTION=mysql
DB_HOST=localhost 
DB_PORT=3306 
DB_DATABASE=your_database_name 
DB_USERNAME=your_database_user_name 
DB_PASSWORD=your_database_password
SUPPORT_OLDER_DB_VERSIONS=false -> set this to true for older db version
```

* `DB_CONNECTION`: Specifies the database connection driver. For MySQL, use `mysql`.
* `DB_HOST`: Specifies the database server host name or IP address. (default is localhost or 127.0.0.1).
* `DB_PORT`: Specifies the port number on which the database server is running (default is 3306 for MySQL).
* `DB_DATABASE`: Specifies the name of the database you want to connect to.
* `DB_USERNAME`: Specifies the username for accessing the database.
* `DB_PASSWORD`: Specifies the password for the database user.
* `SUPPORT_OLDER_DB_VERSIONS`: Set this to `true` if you are using MySQL version below 5.7.7 or MariaDB version below 10.2.2
* Save the Changes: Save the `.env` file after updating the database configuration.

### Step 6 - Setup Email&#x20;

Please refer the dedicated [section](/evaluator/installation/mail-setup.md).

### Step 7 - Setup Queue&#x20;

Please refer the dedicated [section](/evaluator/installation/queue-setup.md).

### Step 8 - Theming

Please refer the dedicated [section](/evaluator/theming.md).

{% hint style="danger" %}
You must follow all the above steps before continuing final step Setup Wizard
{% endhint %}

### Step 9 - Setup Wizard

1. Open your browser and visit:

   ```
   https://yourdomain.com/public/setup
   ```

{% hint style="info" %}
You may notice the **public** suffix in the URL above. This appears because the site’s entry point is located in the project’s **public** folder.

\
Keeping this structure intact is crucial for security reasons. However, you can remove the suffix if needed. Please follow this [guide](/evaluator/faq/installation.md) to do that.
{% endhint %}

1. The **Evaluator** setup wizard will appear.

<figure><img src="/files/BSZkHLXgxHSzAtLEgQ9I" alt=""><figcaption></figcaption></figure>

1. Click **Start Setup**.
2. The setup wizard includes a few steps. Complete all steps to successfully set up the evaluator.
3. You will see a success message once the setup is complete.

{% hint style="info" %}
Refer [installation](/evaluator/installation/requirements.md) issue for common issues.
{% endhint %}

<figure><img src="/files/1qDWvq8sOAPQjrpkZ65T" alt=""><figcaption></figcaption></figure>

Congratulations! You’re all set to use the evaluator. 🥳


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://lakm.gitbook.io/evaluator/installation/shared-hosting-cpanel.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
