安装Laravel 4时出现"Laravel requires the Mcrypt PHP extension"错误
大家好!我是PHP和Laravel的新手,尝试在本地服务器(Windows上的OpenServer)上安装Laravel 4。我按照说明操作:下载并安装了Composer,打开控制台,输入`composer create-project laravel/laravel myproject --prefer-dist`。开始下载,但随后进程中断并出现错误:
```
Your requirements could not be resolved to an installable set of packages.
Problem 1
- laravel/framework v4.2.17 requires ext-mcrypt * -> the requested PHP extension is missing from your system.
- laravel/framework v4.2.16 requires ext-mcrypt * -> the requested PHP extension is missing from your system.
- ...
```
我检查了phpinfo() — 没有mcrypt部分。在php.ini中取消注释了`extension=php_mcrypt.dll`这一行,但没有任何变化。我重启了服务器,用`composer clear-cache`命令清除了Composer缓存,但错误仍然存在。
请告诉我如何正确为Laravel 4启用PHP的Mcrypt扩展?也许需要