skip to Main Content

*Installing laravel/laravel (v10.0.4)
Failed to download laravel/laravel from dist: The zip extension and unzip/7z commands are both missing, skipping.
The php.ini used by your command-line PHP is: C:xamppphpphp.ini
Now trying to download from source

  • Syncing laravel/laravel (v10.0.4) into cache*

When ever i want to download laravel using command line i’m getting the above error

Some how i have installed the laravel latest version of 10.

and trying to run the dev server using php -S localhost:8080 -t public then this error arises

*
Warning: require(C:UsersHilalDesktoplaravel-10public/../vendor/autoload.php): Failed to open stream: No such file or directory in C:UsersHilalDesktoplaravel-10publicindex.php on line 12

Fatal error: Uncaught Error: Failed opening required ‘C:UsersHilalDesktoplaravel-10public/../vendor/autoload.php’ (include_path=’C:xamppphpPEAR’) in C:UsersHilalDesktoplaravel-10publicindex.php:12 Stack trace: #0 {main} thrown in C:UsersHilalDesktoplaravel-10publicindex.php on line 12*

then i deleted vendor folder and composer.lock file the installed the vendor using this command composer install

But still i’m not able to run the project.

2

Answers


  1. I have already encountered this error before.
    Try opening the php.ini file first —> C:xamppphpphp.ini.
    In this file, at line 962, you can see that the line ";extension=zip" is commented out.
    It would therefore be necessary to remove the semicolon for this line to be taken into account.
    Once this line has been modified, you can save the file, and start the installation again by typing composer create-project laravel/laravel example-app.
    Don’t forget to delete what has already been installed without this modification.

    I hope my answer will help you the best

    Login or Signup to reply.
  2. You could consider editing your php.ini file under Apache server.
    Access your XAMPP GUI, In the options under Apache, click config.
    Select the PHP(php.ini) file.
    Use the search / find functionality or in windows, you can use CTRL + F to achieve the same.
    In the search box, input extension=zip then search.
    In the line that it is found, remove the semicolon that is before it, save and rerun your script.

    It should work.

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