Last active
May 3, 2017 13:05
-
-
Save hn-support/a446afc36363d8d997370398612f4690 to your computer and use it in GitHub Desktop.
Verify curl ssl connections with php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
This script tests whether your php installation is able to create TLS connections. | |
*/ | |
foreach ([6, 7, 8] as $version) { | |
$ch = curl_init(); | |
curl_setopt($ch, CURLOPT_URL, "https://tlstest.paypal.com/"); | |
curl_setopt($ch, CURLOPT_SSLVERSION, $version); | |
var_dump(curl_exec($ch)); | |
var_dump(curl_error($ch)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment