Installing Yii2 Not Working

Yes, PHP 7.4.0. You will need an update (or a previous version).

Okay… Its PHP 7.4.0 the current version let me install the previous version which is 7.3.0

I have used all these PHP versions still no change still the same

Sure about CLI version (php -v)?

Yes I am sure …

I am using Wampserver version 3.2.0 - 64bit - services

Read more here

I just downloaded the advanced template and tried the init script on opensuse (php 7.4.6). It stops as expected.

Oh yes, I remember now. This was a Windows-specific problem.

Okay how do I solve the issue…

I downloaded the advanced template to my Windows 10 with XAMPP (php 7.3.2).
The init script stops as expected.

Additional info: updated to php 7.4.6 available in latest download. Works.

Hmm…something is not right,

Use Laragon instead of XAMPP.

How do we fix this while using Wamp or xampp…

Or the problem cannot be solved in this Forum…

Yes, you are right. It’s not a problem for this forum.
You have to get hold of a better PHP version.

But I added to my previous post about XAMPP there’s a recent version with PHP 7.4.6.
So it’s up to you to switch environment or search for some other solution.
(Because I just installed XAMPP for reference and not using it, I can’t tell what’s the best solution for Windows.)

I dont think the problem its about php because i have used different type of php versions still same result.
I guess its the Yii2 Framework itself I bet i have to look for another framework. I really liked Yii framework and also this Forum has no much of help.

Anyhu thanks @tri you really tried.

No, this is not a problem with the framework itself. It’s a problem with initialisation of the advanced application template. Why don’t you just start with the basic template and begin to learn more about the framework?
On the other hand, as a programmer you should be able to analyse what that initialisation script is used for and solve your problem by modifying it. If you don’t want to follow my advice, that is.


its not a Yii-Bug but a php bug wich was fixed with 7.4.1 release: Fixed bug [#78883]( (fgets(STDIN) fails on Windows)

I just linked to another thread where the bug is mentioned.
That at least didn’t work. :grinning:

check this

Do you have the the PHP directory in your Windows 10 environment’s PATH statement.

The PATH also needs to be updated when you switch to alternate PHP versions. Unlike XAMPP and other AMP stacks, WAMP64 does not handle this automatically during installation.

Have you tried installing this on Cloud server? I was surfing to install yii2 on cloud and fortunately found some productive link.