Facebook: SSL Connection Timeout

https://www.phpflow.com/php/facebook-ssl-connection-timeout/

Facebook: SSL Connection Timeout

Last Updated On: December 21, 2015| By: Parvez

Today I am accessing facebook api to get insights of page, But I was getting “SSL connection timeout” error.In this tutorial I will described how to remove this error.

I Was Getting Bellow Error.

1

( ! ) Fatal error: Uncaught CurlException: 28: SSL connection timeout thrown in D:\wamp\www\Facebook\FaceBookSDK\facebook-php-sdk\src\base_facebook.php on line 759

To Remove Error Need To Follow Below Steps.

Step 1: open base_facebook.php Step 2: Find below array in above file. public static $CURL_OPTS = array( CURLOPT_CONNECTTIMEOUT => 10, CURLOPT_RETURNTRANSFER => true, CURLOPT_TIMEOUT => 60, CURLOPT_USERAGENT => 'facebook-php-3.2', );

Step 3: Change CURLOPT_CONNECTTIMEOUT = 30 setting public static $CURL_OPTS = array( CURLOPT_CONNECTTIMEOUT => 30, CURLOPT_RETURNTRANSFER => true, CURLOPT_TIMEOUT => 60, CURLOPT_USERAGENT => 'facebook-php-3.2', );

Last updated