skip to Main Content

I am new to Laravel. I have installed laravel on localhost using: composer create-project laravel/laravel news. Then, server.php to index.php, and copied .htaccess from public to root. However, the installation is displaying laravel default welcome view, successfully.

The pain starts, when I have uploaded it to the server. At first, it’s displaying following message:
Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.0.2".

I have added the following lines to the composer.json (in config):
"platform-check": false
and then omposer dump-autoload. By doing this, above message gone, and the page is displaying 500 Internal Server Error.

I have tried every possible solution, still nothing working till now.

Laravel Version: 8.74.0
Server Php Version: 7.4.26

Please help me to solve this issue. If you need any other information, I will provide.

2

Answers


  1. Try installing a lower version of laravel. For example:

    composer create-project laravel/laravel=8.0.* news

    Login or Signup to reply.
  2. I think it is better to add a php8 version on your local than downgrading your laravel version to 7.

    Your Composer dependencies require a PHP version ">= 8.0.2" – tells that your laravel require you to have have php version 8.0.2 or higher.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search