facebook-php-sdk

Facebook Auth Dialog: Developer warning concerning the use of “display” type “popup”

拥有回忆 提交于 2019-12-20 12:02:06
问题 starting today we receive developer warnings in the auth dialog with the following message: You are using a display type of 'popup' in a large browser window or tab. For a better user experience, show this dialog with our JavaScript SDK without specifying an explicit display type. The SDK will choose the best display type for each environment. Alternatively, set height and width on your window.open() call to properly size this dialog if you have special requirements precluding you from using

Facebook Auth Dialog: Developer warning concerning the use of “display” type “popup”

大憨熊 提交于 2019-12-20 12:01:56
问题 starting today we receive developer warnings in the auth dialog with the following message: You are using a display type of 'popup' in a large browser window or tab. For a better user experience, show this dialog with our JavaScript SDK without specifying an explicit display type. The SDK will choose the best display type for each environment. Alternatively, set height and width on your window.open() call to properly size this dialog if you have special requirements precluding you from using

Getting Fatal Error Uncaught CurlException: 26: couldn't open file

南楼画角 提交于 2019-12-20 07:22:54
问题 I am trying to create a dynamic image of my friends using PHP's GD Library, and I need to upload this to my Friends Profile but I keep getting an Error Fatal error: Uncaught CurlException: 26: couldn't open file "" thrown in /home/p170r760/public_html/myfbapps/mysupporters/base_facebook.php on line 820 $image = imagecreatetruecolor(500, 500); $orange = imagecolorallocate($image, 0xFF, 0x8c, 0x00); $bg = imagecreatefromjpeg('app2_bg.jpg'); imagesettile($image, $bg); imagefilledrectangle($image

Facebook Graph API 2017 - Image uploaded to Timeline Photos instead of given Album (id)

柔情痞子 提交于 2019-12-20 07:18:29
问题 My users can decide if they want to upload to the main timeline of their page or into one of the page albums. Everything works successfully, except the fact my images being uploaded to the Timeline Photos (default FB album) instead of the selected one. $timelinealbum is "me" if the timeline is selected, and it's the "%album_id%", if one of the albums selected. So the post url is "/me/photos" for timeline, and "/%album_id%/photos" for album. Debugged, working well. Photos still go to Timeline

Get facebook user if only logged in facebook php sdk

醉酒当歌 提交于 2019-12-20 06:15:23
问题 I want to get current loggedin facebook user in php sdk. Here is what i have tried: $facebook = new \Facebook(array( 'appId' => 'XXXXXXXXXXX', 'secret' => 'XXXXXXXXXXXXXXXXXXXXX', )); $user = $facebook->getUser(); var_dump($user); if ($user) { $logoutUrl = $facebook->getLogoutUrl(); echo $logoutUrl; } else { $loginUrl = $facebook->getLoginUrl(); echo $loginUrl; } When I load the page with above code, I get the loginUrl even though I am logged in facebook. Only when i load $loginUrl in the

Is it possible to get Facebook feed, likes and comments from a closed group that I own using the Facebook API + PHP

不问归期 提交于 2019-12-20 05:44:14
问题 I want to build a web application that gets feed, likes and comments from a closed group that I own - using the Facebook API + PHP I saw that I can get information using this Graph API interface, started reading the facebook docs and got to a point that I start thinking that I cant actually do that: https://developers.facebook.com/docs/public_feed/ But still there is this: https://developers.facebook.com/docs/graph-api/reference/v2.2/group/feed and I just cant find the function that gets the

FB API PHP curl_setopt_array(): The usage of the @filename API for file uploading is deprecated

▼魔方 西西 提交于 2019-12-20 04:38:28
问题 Have a problem with FB PHP API and php 5.5 with uploading photo to server. When using method : private function _upload( $type = '', $path = '', $message = '', $aid = '' ) { try { if ( !in_array( $type, array( 'photos', 'videos' ) ) ) { throw new \Exception( 'Error: Incorrect type ' ); } if ( !self::getFB()->getUser() ) { throw new \Exception( 'Error: No user' ); } if ( empty( $path ) ) { throw new \Exception( 'Error: path is empty' ); } if ( !file_exists( realpath( $path ) ) ) { throw new

Facebook account delink or deauthorize facebook app and check status of linking from facebook app

给你一囗甜甜゛ 提交于 2019-12-20 03:17:30
问题 My website application having feature login with Facebook login. And for which my app is present on Facebook. Login with facebook is working fine. But application have feature of linking and unlinking facebook account to Facebook app. How to check FB account is linked with specific FB app or not? And how to unlink FB account from specific FB app if linked (On that user's request )? ("Linked" means we select "Allow" to FB app on request) 回答1: With the new Graph there is a documented way to

how to hide page post using facebook api

喜你入骨 提交于 2019-12-20 03:13:14
问题 I have this code and It's from this link https://developers.facebook.com/docs/reference/api/page/ (Please see 'Hiding a Page Post') I don't have any error but my problem is, this code is not working. the page post is still not hidind Below is my code: $fanpage_credit = array( 'access_token' => $page_token, 'is_hidden' => true ); $fanpage_post_url = '/'.$post_id; $postResult = $facebook->api($fanpage_post_url, 'post', $fanpage_credit ); echo 'HIDE SUCCESS '.time(); I look forward for answers.

Facebook Open Graph API returns: (#200) Requires extended permission: publish_actions

别说谁变了你拦得住时间么 提交于 2019-12-20 03:07:58
问题 I am trying to publish actions to a user's wall using the Open Graph API. I requested the 'publish_actions' permission, enabled the 'Enhanced Auth Dialog', my role is set to 'developer' and my app settings show 'This app may post on your behalf, including pictureabcs you viewabcked and more.'. Requesting $facebook->api('/me/permissions'); returns array(1) { ["data"]=> array(1) { [0]=> array(2) { ["installed"]=> int(1) ["publish_actions"]=> int(1) } } } However, when I send the following post