gpt4 book ai didi

php - 无法通过 Composer 在Windows上安装laravel 5

转载 作者:可可西里 更新时间:2023-11-01 14:01:15 25 4
gpt4 key购买 nike

我正在尝试在 Windows 上开始使用 laravel,这是我尝试过的命令:

rahul@rahulserver MINGW64/d/PhpIdeaProjects/LaravelLearning
$ composer create-project laravel/laravel learning-laravel-5

这是我得到的输出:

Installing laravel/laravel (v5.0.22)
- Installing laravel/laravel (v5.0.22)
Loading from cache

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

Problem 1
- Installation request for danielstjules/stringy 1.9.0 -> satisfiable by danielstjules/stringy[1.9.0].
- danielstjules/stringy 1.9.0 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
Problem 2
- Installation request for laravel/framework v5.0.16 -> satisfiable by laravel/framework[v5.0.16].
- laravel/framework v5.0.16 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.

那么我该如何继续前进并让它发挥作用呢?

最佳答案

请求的依赖项需要 php 扩展名 mbstring,正如错误所解释的那样。

the requested PHP extension mbstring is missing from your system

所以安装扩展,它应该安装完美。

mbstring 内置于 libapache2-mod-php5 包中。运行

sudo apt-get install libapache2-mod-php5


对于 Windows 环境,检查您的 php.ini 并取消注释行 ;extension=php_mbstring.dllextension=php_mbstring.dll - 然后重新启动您的网络服务器。

关于php - 无法通过 Composer 在Windows上安装laravel 5,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33933803/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com