Thanks for reporting your experience.
~ Much appreciated.
The ideal PHP configuration is this:PHP 5.2+ with cURL enabled on a Linux/Unix operating system.
This is the default configuration by most hosting companies ( not all, but most ).In your php.ini file, you'll want to have this line in case cURL is not enabled by your hosting provider:
- Code: Select all
allow_url_fopen = On
This is the default on most servers ( allow_url_fopen = On ).s2Member will try to use cURL first. If cURL is not available, s2Member will try to use the FOPEN method, in which case the allow_url_fopen = On setting will be required.-----------------------------------------------
If you're running WordPress on a Windows server:You'll want to disable the cURL extension because Windows servers usually do not play nice with cURL over the HTTPS protocol. So instead, you can just disable the cURL extension. This way s2Member will use the FOPEN method; in which case you will need to have this in your php.ini file:
- Code: Select all
;extension=php_curl.dll
extension=php_openssl.dll
allow_url_fopen = On
The cURL extension is commented out ( disabled ).------------------------------------------------
In ALL CASES, your installation of PHP must be compiled with support for HTTPS connections. If you're racking your brain over problems connecting to PayPal, it's probably because your installation of PHP is not compiled with the OpenSSL extension. In other words, your server can't connect to any URL that starts with
https://. Almost ALL major hosting companies come with OpenSSL pre-compiled. That being said... if you're running your own server, you may have forgotten. The best way to test this, is to load this file on your server and open it in a browser. If OpenSSL was not compiled, you will get an error to that affect.
- Code: Select all
<?php
ini_set("display_errors", true);
ini_set("error_reporting", E_ALL);
echo file_get_contents("https://www.paypal.com/");
?>