CakePHP 3.1.1安装错误

时间:2015-09-24 15:47:23

标签: php xampp cakephp-3.0

我为Windows file.exe安装了Composer,并且第一次尝试安装cakePHP 3.1.1,但是得到了以下错误。文件[CakePHP311]在该文件夹中创建,还有XAMPP [PHP版本5.6.8] + Windows 10 Pro。

这个错误和cakePHP文件需要重新设置是什么?

User@cccc/C/xampp/htdocs/cakePHP_Blog
$ composer create-project --prefer-dist cakephp/app cakePHPblog
Installing cakephp/app (3.1.1)
  - Installing cakephp/app (3.1.1)
    Downloading: 100%

Created project in cakePHPblog
Loading composer repositories with package information
Installing dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

问题

- cakephp/cakephp 3.1.x-dev requires ext-intl * -> the requested PHP extensi on intl is missing from your system.
- cakephp/cakephp 3.1.0-beta2 requires ext-intl * -> the requested PHP exten sion intl is missing from your system.
- cakephp/cakephp 3.1.0-beta requires ext-intl * -> the requested PHP extens ion intl is missing from your system.
- cakephp/cakephp 3.1.0-RC1 requires ext-intl * -> the requested PHP extensi on intl is missing from your system.
- cakephp/cakephp 3.1.0 requires ext-intl * -> the requested PHP extension i ntl is missing from your system.
- Installation request for cakephp/cakephp ~3.1 -> satisfiable by cakephp/ca kephp[3.1.0, 3.1.0-RC1, 3.1.0-beta, 3.1.0-beta2, 3.1.x-dev].

2 个答案:

答案 0 :(得分:2)

php-intl 插件缺失时发生此错误。

如果您使用Linux,则可以尝试 apt-get install php5-intl yum install php-intl 命令。

答案 1 :(得分:0)

确保已安装并启用扩展程序php_intl。它与XAMPP安装捆绑在一起,但可能未启用。您可以通过检查php.ini(位于/xampp/php/php.ini)中的以下行来启用它,该行可能会被注释掉并删除注释:

;extension=php_intl.dll

TO(删除分号)

 extension=php_intl.dll

然后,您需要从Xampp控制面板重新启动Apache。