我們正在嘗試使用Facebook連接登錄。 它可以在本地主機,但無法在這條線的服務器上:facebook PHP SDK SSL錯誤 - 爲什麼?
$user_profile = $facebook->api('/me');
有Facebook的例外:
object(FacebookApiException)#2 (8) {
["result":protected]=>
array(2) {
["error_code"]=>
int(60)
["error"]=>
array(2) {
["message"]=>
string(146) "SSL certificate problem, verify that the CA cert is OK. Details:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed"
["type"]=>
string(13) "CurlException"
}
}
["message":protected]=>
string(146) "SSL certificate problem, verify that the CA cert is OK. Details:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed"
["string":"Exception":private]=>
string(0) ""
["code":protected]=>
int(60)
["file":protected]=>
string(43) "C:\xampp\htdocs\taska\api\base_facebook.php"
["line":protected]=>
int(967)
["trace":"Exception":private]=>
array(5) {
[0]=>
array(6) {
["file"]=>
string(43) "C:\xampp\htdocs\taska\api\base_facebook.php"
["line"]=>
int(899)
["function"]=>
string(11) "makeRequest"
["class"]=>
string(12) "BaseFacebook"
["type"]=>
string(2) "->"
["args"]=>
array(2) {
[0]=>
string(29) "https://graph.facebook.com/me"
[1]=>
array(2) {
["method"]=>
string(3) "GET"
["access_token"]=>
string(48) "2750040a2d1e2"
}
}
}