Start the migration to yii2 via the console.
Error:
PHP Parse error: syntax error, unexpected '[', expecting ')' in /public_html/device/vendor/yiisoft/yii2/Yii.php on line 25
There was a suspicion that the version of php < 5.4.
Look
phpinfo()
shows
PHP Version 5.6.18.
from the console run
php-v
PHP 5.3.29 (cli) (built: Aug 21 2014 13:46:08)
The first question is who to believe? I understand still version 5.6?
Then the second question is why such error occurs during migration?
-------------------------
Update
used:
php yii migrate/mark m160005_174529_users
and had:
/opt/php56/bin/php yii migrate/mark m160005_174529_users
because the version of php in the console by default was 5.3