我正在尝试学习Symfony ...开始阅读教程,似乎最好的入门方法是在Symfony安装程序中使用build。所以我在我的USB钥匙驱动器上安装了uwamp。它似乎工作正常,因为当我导航到localhost时,测试页面打开了。
PHP版本设置为7.0.3,当我打开Windows控制台并键入php -v时,选择了正确的版本,因此我设置了正确的全局路径。
我检查了所有PHP和Apache模块,并确保我所有必需的东西都不能包括OpenSSL和curl以及所有其他推荐的东西。实际上,所有这些都已经预先配置了uwamp安装(谢谢你)
因此,当我尝试使用Symfony命令时,这就是我得到的:
[GuzzleHttp\Exception\RequestException]
Error creating resource: [message] fopen(): Unable to find the wrapper "https" - did you forget to enable it when y
ou configured PHP?
[file] phar://J:/UwAmp/www/symfony/vendor/guzzlehttp/ringphp/src/Client/StreamHandler.php
[line] 406
[message] fopen(https://get.symfony.com/symfony.version): failed to open stream: Invalid argument
[file] phar://J:/UwAmp/www/symfony/vendor/guzzlehttp/ringphp/src/Client/StreamHandler.php
[line] 406
[message] Undefined variable: http_response_header
[file] phar://J:/UwAmp/www/symfony/vendor/guzzlehttp/ringphp/src/Client/StreamHandler.php
[line] 407
我不明白......我确实设置了OpenSSL ......我还需要做什么?我甚至手动检查了ini文件并确保删除了半号。
答案 0 :(得分:0)
好的,经过大量的挖掘,我终于找到了解决问题的方法。
就我而言:
extension_dir = "J:\UwAmp\bin\php\php-7.0.3\ext"
zend_extension = "J:\UwAmp\bin\php\php-7.0.3\zend_ext\php_xdebug.dll"
据我所知,Windows CLI不使用php_uwamp.ini文件,并使用默认值。使用更正的扩展路径创建名为php.ini的文件将使其正常工作。