Hi,
I test Social Integration Service, when I test Update Facebook Status and Get Facebook Friends From Link User, I get Error message below :
In Update Facebook Status
Fatal error: Call to undefined method com\shephertz\app42\paas\sdk\php\social\Social::getFriendList() in /home/ideabusd/public_html/guotest/app42/FBSDK_PHP/index.php on line 111
In Get Facebook Friends From Link User
Fatal error: Uncaught exception 'com\shephertz\app42\paas\sdk\php\App42BadParameterException' in /home/ideabusd/public_html/guotest/app42/FBSDK_PHP/PHP/1.2/RestClient.class.php:326 Stack trace: #0 /home/ideabusd/public_html/guotest/app42/FBSDK_PHP/PHP/1.2/SocialService.php(167): com\shephertz\app42\paas\sdk\php\connection\RestClient::post('https://api.she...', Array, NULL, NULL, 'application/jso...', 'application/jso...', '{"app42":{"soci...') #1 /home/ideabusd/public_html/guotest/app42/FBSDK_PHP/index.php(101): com\shephertz\app42\paas\sdk\php\social\SocialService->updateFacebookStatus('guo04', 'AAA is using th...') #2 {main} thrown in /home/ideabusd/public_html/guotest/app42/FBSDK_PHP/PHP/1.2/RestClient.class.php on line 326
This is my code(PHP)
Update Facebook Status
$userName = "guo04";
$status = "AAA is using the App42 API";
$social = $socialService->updateFacebookStatus($userName, $status);
Print_r("userName is" . $social->getUserName()."<br/>");
Print_r("status is" . $social->getStatus()."<br/>");
$jsonResponse = $social->toString();
print_r($jsonResponse);
Get Facebook Friends From Link User
$userName = "guo04";
$social = $socialService->getFacebookFriendsFromLinkUser($userName);
Print_r("<br/><br/>userName is " . $social->getUserName()."<br/>");
Print_r("<br/>Installed is " . $social->getFriendList()->get(0)->getInstalled()."<br/>");
Print_r("<br/>Id is " . $social->getFriendList()->get(0)->getId()."<br/>");
Print_r("<br/>Name is " . $social->getFriendList()->get(0)->getName()."<br/>");
$jsonResponse = $social->toString();
print_r($jsonResponse);
Does my code wrong or I forget something ?
Thank you !