I was having problem in Windows 7 with PHP 5.4.0 in command line, using Xampp 1.8.1 server. This is what i did:
php.ini-production
to php.ini
(in C:\xampp\php\ folder)php.ini
and uncomment extension_dir=ext
.extension=php_openssl.dll
.After that it worked fine.