作曲家:您的系统缺少所需的PHP扩展名ext-intl * [英] Composer: The requested PHP extension ext-intl * is missing from your system

查看:318
本文介绍了作曲家:您的系统缺少所需的PHP扩展名ext-intl *的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用 composer.json 文件。但是,当我尝试在 path / project / 中运行命令' composer install 时,错误:

I am trying to use composer.json file. but, when I am trying to run command 'composer install' in my path/project/, I am getting an error:

我已经为<< c $ c> extension = php_intl.dll wamp >,然后将所有 icu * .dll 复制到 D:wamp\bin\apache\apache2.2.22\bin '从' D:wamp\bin\php\php5.3.13 '开始,它显示在 phpinfo中()

I have already configured my wamp for 'extension=php_intl.dll' and copied all icu*.dll in 'D:\wamp\bin\apache\apache2.2.22\bin' from 'D:\wamp\bin\php\php5.3.13' and it's showing in phpinfo():

无副本 icu * .dll 也可以显示在中phpinfo();

without copy icu*.dll also works and showing in phpinfo();

请告诉我我是否有 intl 安装在我的 沼泽 composer安装 在我的电脑上,然后为什么我收到此错误。

Kindly, let me know if I have intl install on my wamp and composer install on my pc then why I am getting this error. really, it is so annoying.

这是我的详细信息:


  1. OS :Windows 7(64)

  2. PHP:5.3.13

  3. Apache:2.2.22

  4. Composer :由可执行文件安装

  5. 梨:已安装(最新)

  6. PHPUnit:已安装(最新)

  1. OS: windows 7 (64)
  2. PHP: 5.3.13
  3. Apache:2.2.22
  4. Composer: installed by executable file
  5. Pear: installed (latest)
  6. PHPUnit: installed (latest)

我的 composer.json 如下:

My composer.json is as below:

{
    "name" : "sebastian/money",
    "description" : "Value Object that represents a monetary value (using a currency's smallest unit)",
    "keywords" : ["money"],
    "homepage" : "http://www.github.com/sebastianbergmann/money",
    "license" : "BSD-3-Clause",
    "authors" : [{
            "name" : "Sebastian Bergmann",
            "email" : "sebastian@phpunit.de"
        }
    ],
    "require" : {
        "php" : ">=5.3.3",
        "ext-intl" : "*"
    },
    "require-dev" : {
        "phpunit/phpunit" : "~4.0"
    },
    "autoload" : {
        "classmap" : [
            "src/"
        ]
    },
    "extra" : {
        "branch-alias" : {
            "dev-master" : "1.3.x-dev"
        }
    }
}

让我知道是否需要其他详细信息。.

Let me know if any other details is required..

任何反馈/帮助将不胜感激。

Any feedback/help would be highly appreciated.

推荐答案

wamp的问题通常是,它对命令行php使用的php.ini与对web / apache php使用的php.ini不同。因此,您在浏览器中的phpinfo()中看到了intl扩展名,但是如果在命令行中运行 php -m ,则应该看到那里的扩展名列表不包括int。

The problem with wamp usually is that it uses a different php.ini for command line php than for the web/apache php. So you see the intl extension in phpinfo() in the browser, but if you run php -m in the command line you should see that the list of extensions there does not include intl.

您可以在输出顶部使用 php -i 检查它应该告诉您ini文件的位置从加载。确保在该ini文件中启用了intl扩展名,您应该会很好。

You can check using php -i on top of the output it should tell you where the ini file is loaded from. Make sure you enable the intl extension in that ini file and you should be good to go.

对于php.ini 5.6版本(使用php -v检查版本) p>

For php.ini 5.6 version (check version using php -v)

;extension=php_intl.dll 
; remove semicolon
extension=php_intl.dll

对于php.ini 7. *版本

For php.ini 7.* version

;extension=intl
; remove semicolon
extension=intl

这篇关于作曲家:您的系统缺少所需的PHP扩展名ext-intl *的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆