我正在尝试在Yii2中安装2amigos date picker,但我收到以下错误:
C:\xampp\htdocs\advanced>php composer.phar require "2amigos/yii2-date-picker-widget" "*"
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- yiisoft/yii2 2.0.2 requires bower-asset/jquery 2.1.*@stable | 1.11.*@stable -> no matching package found.
- yiisoft/yii2 2.0.2 requires bower-asset/jquery 2.1.*@stable | 1.11.*@stable -> no matching package found.
- Installation request for yiisoft/yii2 == 2.0.2.0 -> satisfiable by yiisoft/yii2[2.0.2].
Potential causes:
- A typo in the package name
- The package is not available in a stable-enough version according to your minimum-stability setting
see <https://groups.google.com/d/topic/composer-dev/_g3ASeIFlrc/discussion> for more details.
Read <http://getcomposer.org/doc/articles/troubleshooting.md> for further common problems.
Installation failed, reverting ./composer.json to its original content.
我已尝试修改composer.json
文件,将minimum-stability
更改为dev
,但这仍然无效。
答案 0 :(得分:3)
确保使用以下命令安装composer asset插件:
composer global require "fxp/composer-asset-plugin:1.0.0"
它应该只执行一次。
在official guide和plugin official documentation中了解详情。
如果在安装过程中遇到其他问题,请使用composer
命令将self-update
更新为最新版本。