I'm attempting to install Composer but I get the following error:
"Some settings on your machine make Composer unable to work properly. Make sure that you fix the issues listed below and run this script again:
The openssl extension is missing, which means that secure HTTPS transfers are impossible. If possible you should enable it or recompile php with --with-openssl"
I have then gone into my php.ini-production and uncommented: "extension=php_openssl.dll"
This still doesn't work though, is there something else I have to do?
If you are using MAMP on Windows, you need to change the extension for php.ini-development
to php.ini
Then, paste this line ;extension_dir = "ext"
into the php.ini file, before the first extension appear, and uncomment this other line ;extension=php_openssl.dll
removing the prefixed semicolon.
Dont't forget to restart apache
I suspect "php.ini-production" is a dummy configuration file suitable for live environments. Do a php -i
at the console and find the 'php.ini' path, to see where it is expecting the ini file to be kept. This is normally expecting "php.ini", and may not actually exist - if it does not, copy php.ini-development (or similar) to the location required.
This is near the top of (a very long) output, so you may find redirecting it to a file helpful (php -i > C:\phpinfo.txt
).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With