Title: Login button and server-side authentication
Tags: java;facebook-graph-api;authentication;facebook-authentication;facebook-login
Question: I added a facebook login-button to my website, that works great, I can successfully make javascript calls to the API using FB.api().
But now I would like to know from the server side if the user is logged in, and send some user information from client side to server side. Or even better if possible : use the client side authentication to make API calls from the server side.
How can I do that?
Thanks a lot!

Here is the accepted answer: PHP-sdk works great with javascript-sdk
refer to https://developers.facebook.com/docs/reference/php/
refer to https://developers.facebook.com/blog/post/534/  This example
shows how to auth php with javascript.
Comment for this answer: Thanks but this is a java web application.
Comment for this answer: @KayKay If i come across a java-sdk i will post to you.
EDIT: https://github.com/facebook/facebook-android-sdk for android not sure if this you can use or pick apart.


{'source': 'StackExchangeDataset', 'subset': 'stackoverflow.com', 'metadata': {'AnswerCount': 1, 'CommentCount': 0, 'ContentLicense': 'CC BY-SA 3.0', 'CreationDate': '2011:00:10/29/11', 'FavoriteCount': None, 'PostTypeId': 1, 'Tags': '<java><facebook-graph-api><authentication><facebook-authentication><facebook-login>', 'Title': 'Login button and server-side authentication', 'ViewCount': 688, 'id': 7941818, 'user_AboutMe': '<p>Freelance software engineer.</p>\n\n<p>Java, Spring, REST, AngularJS, Cassandra</p>\n\n<p><a href="https://fr.linkedin.com/in/k%C3%A9vin-gautron-254b9214" rel="nofollow">https://fr.linkedin.com/in/kévin-gautron-254b9214</a></p>\n', 'user_AccountId': 256707.0, 'user_DisplayName': 'kgautron', 'user_Reputation': 7618.0, 'user_Views': 446.0, 'user_id': 537623.0}}