Reputation: 941
I tried to Install composer on my PC (Windows 8 Pro 64x and XAMPP 3.2.1), so I downloaded Windows Installer and run it But I got this error:
The openssl extension is missing, which means that secure HTTPS transfers are impossible.
I searched about this problem and I tried some solutions
extension=php_openssl.dll
was uncomment in php.ini file in C:\xampp\php\php.ini and there's no other php.ini file on my system (I searched for it)
Also when I run "php --ini" command in CMD, I get this:
Configuration File (php.ini) Path: C:\windows
Loaded Configuration File: (none)
Scan for additional .ini files in: (none)
Additional .ini files parsed: (none)
if it helps.
I hope someone helps me. Tnx
Upvotes: 2
Views: 10242
Reputation: 55
Even I had this error while installing composer in my PC, try this:
1- Open C:\php\php.ini
2- Find ;extension=openssl and remove ; , save it
3- Now go to
C:\xampp\php\ext
4- Copy all files
5- Now go to
C:\php\ext
6- Paste these files
Try now :) plz let me know if I did anything wrong
Upvotes: 0
Reputation: 31
I've been battling the same issue since last week but was able to solve it today. First, I'm using XAMPP on Windows 10, so you're home as long as you've got XAMPP running on your PC.
(You may run phpinfo.php to know your settings (you can create a simple script file with that name , check for extension_path. It should point to the 'php\ext' folder (that's where mine is)) I set the path in php.ini to c:\xampp\php\ext. You can get to this file from the XAMPP control panel by clicking on CONFIGURE button corresponding to APACHE web server then, select 'php.ini' from the pop list. Search for extension_path and remove the comment directive (';').
Remember to stop and restart Apache web server from the XAMPP Control Panel.
That's all I did, my php code isn't much different from the one above. Try this and let me know how you fare.
Upvotes: 1
Reputation: 11
";extension=php_openssl.dll" is commented out in the php.ini file. Simply remove the comment, save the file, rerun the Composer Install.
Upvotes: 1
Reputation: 3726
C:\xampp\php\php.ini
is the correct configuration file. Edit it and then make sure to restart Apache service for the change to take effect.
Upvotes: 0