I have faced the following problem during the installation of laravel php framework.
following errors appeared when I run the command composer global require "laravel/ installer".
NB: I already have installed xampp, composer and add these to environment variable.
the following picture will clear the problem. enter image description here
I have used php version 5.6 and tried to install laravel having this version.
Later I have uninstalled xampp and install the latest version of xampp and things are working now
Related
i am newbie with laravel and tryng to download 5.8 version in a server xamp.
But, when i try the command in the terminal of Xamp:
composer create-project --prefer-dist laravel/laravel blog "5.8.*"
returns
[InvalidArgumentException]
Could not find package laravel/laravel with version 5.8.* in a version installable using your PHP verson 8.0.5
Someone have a idea of what i can do?
Laravel 5.8 doesn't support php 8, you should probably consider using laravel 8
Xampp versions follows PHP's, so you should download something like 7.1.3x. This can be done on the download page, assuming you are using windows this is the link.
In general for choosing PHP versions, it is most optimal to go with the version that is used on the production server.
If you really want to use Laravel 5.4, then you'd need to go with PHP 7.* and I'd recommend going with Wamp (https://www.wampserver.com/en/) instead of Xampp, which allows you to switch between php versions with one click.
However try using laravel 8 if laravel 5.4 is not a requirement
I have installed xampp with different php versions of php (5.6 and 7.1) on my C:
when im trying to composer install for the project to have a vendor folder
it reads the php version of 5.6 instead of the 7.1 windows
I tried searching
and i saw one changing on environmental variable but i cant see the path for php versions
i also try Composer does not detect php7 instead it uses 5.6. How can I set the CLI to use php7
but im using git bash not sudo (because ihave Wiondows as OS)
First I had my project running in Ubuntu, but I didn't have enough diskspace. So I made a new environment with more diskspace and I tried to transfer my project to the new environment.
I use virtualbox with Xubuntu 16.04.
PHP version 7.2.3
Composer update or install doesn't work. vendor directory is missing.
What am I doing wrong? screenshot of website.
I have two xampp versions in my machine one have php version 5.4 and other having 7.1(recently installed.) I usually use composer command to download laravel. previously i get laravel version 5.0.X when i download because of my php vesrion(5.4) but even after installing new xampp(having php version 7) composer is downloading laravel 5.0.x only. When i check my php version it is showing 5.4 now how can i choose or connect latest php version to composer so that i will get latest laravel version.
Finally i found the solution. I changed my composer path to new php version and now getting what i want.
I set my Environment variables as follow:
change name of respective document xampp that contains your project I want to launch.
my system context
I have Installed Zend Server 8.0.1 with PHP 5.6.4 on Windows 8.1. I have added 'E:\Program Files (x86)\Zend\ZendServer\bin' to PATH variable, which contains PHP binaries.
I have Installed Composer Globally. I am trying to create a Laravel project using composer command 'composer create-project laravel/laravel'. After a while PHP CLI stops working. Screen shot is below.
screen shot of PHP settings given below.
I tried it few times but same error. Has anybody faced same problem. Unfortunately I don't have tool to analyze Dump.
It is a bug with Zend Server 8.x, PHP 5.6 and composer running on Windows that Zend is aware of (see http://forums.zend.com/viewtopic.php?f=8&p=245953).
Using older version of composer.phar works for me. Get the composer.phar from the Zend Skeleton Application (https://github.com/zendframework/ZendSkeletonApplication) and try with it.