w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML Categories
Video share on facebook wall using Graph API
<meta property="og:video" content="http://staging.derbywire.com/video/player" /> <meta property="og:video:type" content="application/x-shockwave-flash" /> You have to give the URL of the actual SWF file that plays the video here – the address you have given (http://staging.derbywire.com/video/player) however delivers a full HTML document. Facebook is not so silly to just embed full HTML documents into their page. So change that property to the address of a stand-alone SWF file that will play the actual video.

Categories : Facebook

Facebook Graph Api: Share a link with a specified locale?
I believe what you're looking for is post targeting, not the locale. Post targeting allows you to limit posts to the following criteria: Age Gender Relationship Status (“Interested In” in the Advertising create Flow) Language Education College Grad (college name, major year) In high school Workplace Geographic Location Country State City The down side though is that this functionality is only available to Pages, not user posts, however, there is a trick that can give you the same behaviour, but will cost you some time and effort. according to this page, in normal user posts, there is a privacy parameter, that can be customised to exclude users, or only be visible to specific users, what you need to do is: Read user's friend list (and filter countries you want), this will requir

Categories : Facebook

Facebook iOS share open graph story with custom buttons
This is called an "action link". You can read about it here: https://developers.facebook.com/docs/opengraph/howtos/action-links/

Categories : IOS

Add Open Graph Meta Tag After Page is Loaded, for Facebook Share button
I don't think this is possible, since JS code does not get executed. See How does Facebook Sharer select Images? Can I update these meta tags with client side code like Javascript or jQuery? No. Much like search engine crawlers, the Facebook scraper does not execute scripts so whatever meta tags are present when the page is downloaded are the meta tags that are used for image selection.

Categories : PHP

facebook share count not increasing if shared from app
Actually, you are not sharing a content, you are posting in user's wall. I am no expert in Android SDK and I am not sure that this action counts in Facebook share. In WEB version, I would need to use Social Plugins to do that. Looking for other tracks, I have found this one showing how to create an Intent to user share content. I believe that is what you need.

Categories : Android

Rails Display Current Facebook Share Count
data[url]['shares'] part is suspicious. Eithere data[url] gives you Array and when you are trying ['shares'] on that Array you are getting the error,which is obvious. Or data itself is Array of something... Thus data[url] throws the error. So inspect first how data is looks like. This error is coming as Array#[] don't allow string inside []. See the below demo code: arr = [1,2] arr['foo'] # ~> -:2:in `[]': no implicit conversion of String into Integer (TypeError) # ~> from -:2:in `<main>'

Categories : Ruby On Rails

Facebook post comment count from Graph API
Well i don't know your scenario, so can't help you with exact solution. but one way to get comments count is getting it from the stream table using FQL. there is a structure of comment_info which gives the comment count for any specific post. see the query below for example: Select type, post_id, description, likes,comment_info from stream WHERE source_id = "*post_id*" put the post id in the clause.

Categories : Facebook

default comment count in facebook graph API
There is a way to get count of comments back. It's example from developers.facebook.com/tools/explorer SocialMediaClubMoscow?fields=feed.fields(comments.limit(1).filter(toplevel),message,likes,shares,from) }, "summary": { "order": "chronological", "total_count": 12 } total_count - is count of all comments Related topic: Removing 'count' from 'comments' Graph API connection

Categories : Facebook

How to get Likes Count when searching Facebook Graph API with search=xxx
The summary is on the likes connection of the post object just call https://graph.facebook.com/POST_ID/likes?summary=true&access_token=XXXXXXXXXXXX there will be a 'summary' element with a 'total_count' field

Categories : Facebook

how to get my facebook share dialog to display the facebook share button rather than just text?
What you are looking for is the Share Button. Facebook has deprecated this and this will no longer be supported. So, you have to use the Share Dialog instead that you've mentioned.

Categories : Facebook

facebook october 2013 migration affects likes.count field in Graph Api call
Once you have loaded the Facebook page feed: $config = array(); $config['appId'] = your_app_id; $config['secret'] = your_secret_number; $confif['fileUpload'] = false; $facebook = new Facebook($config); $pageid = facebook_page_id; $pagefeed = $facebook->api('/' . $pageid . '/feed'); You can loop through the data and find a field called 'likes'. With an other loop you can get the total number of likes for the corresponding post. If you want the number of likes for a posted comment there is also a field called 'like_count' that directly gives the number of likes for this comment. Retrieving likes count per post : foreach ($pagefeed['data'] as $post) { $likes_number = 0; if (isset($post['likes'])) { foreach ($post[

Categories : PHP

Facebook Doesn't appear on share windows when trying to share an Image
after correcting my childish mistake (see EDIT part in question) and Using this code snippet I finally solved this problem. if anybody knows whats the difference between using contentValue and my approach please share that with me.

Categories : Android

Facebook Graph API - access_token=app_id|app_secret - search Graph API without user login
According to Facebook The following changes will go into effect on July 10, 2013: ..... Graph API search changes App access tokens will be required for all search Graph API calls except Places and Pages. Search for application will no longer be supported.

Categories : C#

2 near identical URL's integrated with Open Graph tags have separate behaviors when doing a Facebook graph call
Well, I think we cannot help you without the real url of the object, so as to see what it is! Have you try both url (the real ones) in facebook debugger: https://developers.facebook.com/tools/debug to see the difference?

Categories : Facebook

Prevent Facebook from grouping Open Graph actions in Graph API?
You need to use a different endpoint: /me/<app_namespace>:<action_name> This will return all actions published by your app for a given action and a given user. For example, using a user access token: https://graph.facebook.com/me/my_cooking_app:bake?access_token=...

Categories : Facebook

Android Share Image from Phone Gallery to Facebook using Facebook API
You could open a stream to the image from the URI and post it that way using ContentResolver. Session session = Session.getActiveSession(); Bitmap photo = BitmapFactory.decodeStream(getContentResolver().openInputStream(uri)); Request request = Request.newUploadPhotoRequest(session, photo, new Request.Callback()); RequestAsyncTask task = new RequestAsyncTask(request); task.execute();

Categories : Android

How can I add a Facebook share button using the Facebook Javascript SDK in an Ajax call?
Try this. <script type="text/javascript"> $(document).ready(function() { $('#share_button').click(function() { FB.ui({ method: 'feed', name: '<%= fb_data[:name] %>', link: '<%= fb_data[:link]%>', picture: '<%= fb_data[:picture] %>', caption: '<%= fb_data[:caption] %>', description: '<%= fb_data[:description] %>' }); }); }); </script> Does it work ?

Categories : Javascript

How to fetch data from given graph URL in facebook graph API
This is just a 2 steps thing Parse the next/previous URL from the response. You can do it yourself or one of the many libraries With the timestamp parsed, just call your function recursively and "since" in the Graph URL. function getFBData(date) { FB.api('/me/photos?fields=created_time&since=' + date, function(response){ var pager = "parse the paging data from facebook" getFBData(pager); }); }

Categories : Javascript

Facebook Graph API & django-facebook - posting links and photos to page feeds
Facebook Graph API PHP SDK posting on page as page Found it. There is a different access token for impersonating the page to post as the page. You get that from /me/accounts and use that token to post as the page. Updated working code: @facebook_required_lazy(scope=['manage_pages', 'publish_stream', 'photo_upload']) def index(request): if request.method == 'POST': form = CPYPosterForm(request.POST) if form.is_valid(): fb = require_persistent_graph(request) msg = form.cleaned_data['msg'] pages = form.cleaned_data['pages'] me_accounts = fb.get('/me/accounts') access_token = None resp = dict() for p in pages: for d in me_accounts['data']: if d['id']

Categories : Django

Fetch facebook user public data, which available without loggining througth Facebook Graph API if any exists
This isn't possible unless you have an access token. The public graph doesn't reflect the browser information it reflects what is given in the documentation https://developers.facebook.com/docs/reference/api/user/

Categories : Java

Facebook Graph API, Development of Facebook page post targeting( make visible only specified country/city )
Try feed_targeting instead of targeting! All parameters which you can target like languages,cities,counties are facebook specific. You can resolve them via autocomplete data : "{'locales':[1001],'countries':[GE],'cities':[825886]}" Nice feature for automatic posting with targeting but so bad documented in the Facebook documentation...

Categories : PHP

Generating list of facebook friends using Facebook's Graph API
First of all you need to add proper permission to access education history of user & user's friends, which you can achieved by doing this but remember user_education_history is to access User education while friends_education_history is for User's friends education history: $params = array( 'scope' => 'user_education_history, friends_education_history, user_location, email'); $loginUrl = $facebook->getLoginUrl($params); And to access education field you have to modify one line from your code like this: $user_profile = $facebook->api('/me?fields=name,education,email','GET'); You can use below code to just print your $user_profile and then parse it according to your requirements: <pre><?php print_r($user_profile); ?></pre> Probably its too late answer f

Categories : PHP

How to get facebook users' public statuses using facebook graph API?
https://graph.facebook.com/PAGE_OR_USER_ID/statuses?access_token=ACCESS_TOKEN works fine if you have a valid access token.

Categories : Facebook

Retrieve zip code of a facebook user by facebook graph API
If you check the documentation for the /me call at https://developers.facebook.com/docs/reference/api/user/ you'll note that there is no reference to the user's zip or postal code. I'd recommend you use ask for the user_location permission and then call /me?fields=location and try to derive the zip code from the information contained therein - this answer http://stackoverflow.com/a/7129344/2091159 - has some information about doing so.

Categories : PHP

Share via facebook/twitter application in android , don't open browser if facebook/twitter is installed on the device
To post something using Facebook than integrate Facebook android sdk Getting Started with the Facebook SDK for Android Use Feed Dialog to post on Facebook. It automatically open fb app if it is installed otherwise open in browser Post to wall public class PhotoViewer extends Activity implements StatusCallback{ Button btnShare; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_photo_viewer); btnShare = (Button) findViewById(R.id.btnShare); btnShare.setOnClickListener(new OnClickListener() { @Override public void onClick(View arg0) { Session.openActiveSession(PhotoViewer.this, true, PhotoViewer.this); }

Categories : Android

Why facebook access token from Spring Social returns empty array, while Facebook Graph Api token works fine
You need to submit a post request to spring social ConnectController for the specific provider e.g. http://wwww.yourdomain:8089/connect/facebook. Spring social then will redirect the user to facebook authorization page where the user will grant your app with the asked permissions and send back a code to your server. Spring social then will exchange that code for an access token. You need to establish a connection for that user to be able to perform requests against FB on his/her behalf. Here is a doc page that might help http://static.springsource.org/spring-social/docs/1.0.0.M2/reference/html/connecting.html

Categories : Java

How can I get facebook cover url from Facebook graph API
To parse the JSON in PHP you are required to use json_decode(returned_facebook_json) and then access the data as you access a Object, for example $JSONString=file_get_contents('http://graph.facebook.com/{user_id or page_id}?fields=cover'); $parsedJSON = json_decode($JSONString); echo $source = $parsedJSON->cover->source; echo $offset_y = $parsedJSON->cover->offset_y;

Categories : PHP

Facebook Share Dialog/Feed Dialog on iOS - how to know if share button or cancel button is tapped
Updating just in case this helps anyone, the following link finally worked for me: https://developers.facebook.com/docs/howtos/ios-6/#nativepostcontroller Though it had it's limitations (doesn't run on iOS < 6), but it successfully returns me when the user cancels out the dialog. Here's the code I used: BOOL displayedNativeDialog = [FBDialogs presentOSIntegratedShareDialogModallyFrom:self initialText:[NSString stringWithFormat:@"%@", url] image:nil url:url handler:^(FBOSIntegratedShareDialogResult result, NSError *error) { if(result == 0) { //Fire our callback } else{

Categories : IOS

HOW TO CONFIG SHARE KIT FOR FACEBOOK IOS?
The version of ShareKit from your link has not been updated for a long time. You can try updated ShareKit 2. Installation is a little bit different, make sure to follow install guide literally.

Categories : IOS

Facebook share button
The easiest way to add Facebook share button would be to visit http://www.facebook.com/share_partners.php and copy the code and paste it in your webpage after replacing the text "url" with the actual URL of the page you want to share. If it is dynamic content, you can use the variable or object name. <script> function fbs_click(){ u=location.href;t=document.title;window.open('http://www.facebook.com/sharer.php?u='+encodeURIComponent(u)+'&t='+encodeURIComponent(t),'sharer','toolbar=0,status=0,width=626,height=436'); return false; } </script> <a href="http://www.facebook.com/share.php?u=<url>" onclick="return fbs_click()" target="_blank"> <img src= "http://b.static.ak.fbcdn.net/images/share/facebook_share_icon.gif?8:26981" alt="" /></a>

Categories : Javascript

android share on facebook sdk 3.0.2
Session s = Session.getActiveSession(); Request request = Request.newStatusUpdateRequest(s, "your msg", new Request.Callback() { @Override public void onCompleted(Response response) { if(response.getError()==null) Toast.makeText(MainActivity.this, "Status updated successfully", Toast.LENGTH_LONG).show(); } }); request.executeAsync(); this will post your message if you are signed in and have provided all the permissions.

Categories : Android

Facebook Share Dialog in iOS
Do you have Facebook App installed on your device? The Share dialog only works if you have the Facebook app installed. From the Share dialog documentation : Tip 1: What if people don't have the Facebook app installed? The Share dialog can't be displayed if people don't have the Facebook app installed. Apps can detect this by calling [FBDialogs canPresentShareDialogWithParams:nil]; and may disable or hide a sharing button or fall back to the Feed dialog to share on the web. See the HelloFacebookSample included with the iOS SDK for an example. From what I saw, iOS 6 will return NO for + canPresentShareDialogWithParams:. It only responds to + canPresentOSIntegratedShareDialogWithSession:. But I could be wrong here. Anyways, this is how I do it - 1. For sharing links : i

Categories : IOS

Share AngularJS URI in Facebook
Try to use encoded string: encodeURIComponent("http://blog.pabloleone.com/#/posts/migrar-galeria-de-imagenes-de-wordpress") http://www.facebook.com/share.php?u=http%3A%2F%2Fblog.pabloleone.com%2F%23%2Fposts%2Fmigrar-galeria-de-imagenes-de-wordpress

Categories : Facebook

Share content on facebook with vb.net?
You can call the facebook share dialog and supply the URL of the site that you want to share. For example https://www.facebook.com/sharer/sharer.php?u={URL_OF_THE_SITE} Now, you have to call this inside your VB.NET application. If you are using the WebBrowser, you can call the Navigate(String) method. Or, if not, you can call the default browser using the start command. You will need to call the Shell function for this. Example: Shell("start https://www.facebook.com/sharer/sharer.php?u={URL_OF_THE_SITE}")

Categories : Vb.Net

Unable to share on Facebook
I am able to Proceed with this now. The issue was with key hash which I was including in facebook developers site. I was getting wrong key due to openssl. I got the correct one by including this piece of code: try { PackageInfo info = getPackageManager().getPackageInfo( YOUR_PACKAGE_NAME, PackageManager.GET_SIGNATURES); for (Signature signature : info.signatures) { MessageDigest md = MessageDigest.getInstance("SHA"); md.update(signature.toByteArray()); Log.d("KeyHash:", Base64.encodeToString(md.digest(), Base64.DEFAULT)); } } } catch (NameNotFoundException e) { } catch (NoSuchAlgorithmException e) { } I got this while I was searching for alternative to generate the key hash.

Categories : Android

How to get Facebook share link owner?
You should be able to add a query string (?ref_id=abcd) to the link parameter of a FB.ui "send". The FB.ui can be a bit finicky with what links it accepts. Please see my answer here for more info on valid links.

Categories : Facebook

addthis share facebook and google+ url
I have test this and this works check it out on JSFiddle <div class="addthis_toolbox" addthis:url="http://example.com/blog/post/2009/05/01" addthis:title="Hooray!"> <ul class="addthis_toolbox addthis_default_style "> <li><a class="addthis_button_facebook"></a></li> <li><a class="addthis_button_twitter"></a></li> <li><a class="addthis_button_google_plusone_share"></a></li> </ul> </div>

Categories : Javascript

Facebook SDK - iOS - Fail to share URL (Error 102)
This usually comes from you setting the FacebookDisplayName in your .plist, but what you set there didn't match the name of your app in your app settings on Facebook. The value you give in FacebookDisplayName must match what you have set on Facebook.

Categories : IOS

Facebook share on mobile device
I just ran into this same problem, and my only solution was to force mobile users to use the desktop version of sharer.php. It looks like ass on mobiles but it functions as expected and was the best way I could find to not completely hose sharing in my app. In the end, my client would rather have working, less-aesthetically pleasing sharing than a proper mobile sharing page that was broken. To do this, all you have to do is add a ?m2w parameter to sharer.php. In your case: http://www.facebook.com/sharer.php?m2w&s=100&p[url]=ENCODEDURL&p[title]=encoded TITLE&p[summary]=encoded description&p[images][0]=encoded

Categories : Facebook

In which iOS does Facebook Share Dialog work in?
SLComposeViewController is only available in iOS6 if that's what you mean? UIActivityViewController is also only available in iOS6. If you're using less than iOS 6.0 then you'll have to fall back on the Facebook SDK etc...

Categories : IOS



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.