![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
This is the LabSpaces site blog. You will find news and site updates here or posts on press or other coverage of the LabSpaces community
My posts are presented as opinion and commentary and do not represent the views of LabSpaces Productions, LLC, my employer, or my educational institution.
Please wait while my tweets load 
![]() |
![]() |
![]() |
![]() |

I've spent the last few nights buried in Facebook's API figuring out how to use their system to login new users. I finally figured it all out and you can now Login to the site and register new accounts using Facebook. The coolest thing is that we can import your data in here for editing to make the registration process essentially hassle free. No one likes constantly entering their work and education information at each new network...
Existing users can now login to the site using Facebook AS LONG AS the primary email address on their facebook account is the same as their email address here. Just click the Facebook Login button, give the login app access to your account, and voila!
I've done some testing of the system but please let me know if you run into any errors and I'll be sure to fix them!
Next on the facebook list is to sync comments on the facebook page with the articles/blogs on the website and vice versa.
This post has been viewed: 4127 time(s)
![]() |
![]() |
Wow That's awesome!! Can you explain how you do it?? Because I want to do the same with my site and after many many hours in the facebook api, I can't achieve it.
$app_id = "YourAppID";
$app_secret = "YourSecretID";
$my_url = "http://www.thePageThatHandlesTheData.php";
$code = $_REQUEST["code"];
if(empty($code)) {
$dialog_url = "http://www.facebook.com/dialog/oauth?client_id="
. $app_id . "&redirect_uri=" . urlencode($my_url) ."&scope=user_about_me,user_education_history,user_interests,user_location,user_website,user_work_history,email,publish_stream";
echo("<script> top.location.href='" . $dialog_url . "'</script>");
}
$token_url = "https://graph.facebook.com/oauth/access_token?client_id="
. $app_id . "&redirect_uri=" . urlencode($my_url) . "&client_secret="
. $app_secret . "&code=" . $code;
$access_token = file_get_contents($token_url);
$graph_url = "https://graph.facebook.com/me?" . $access_token;
$user = json_decode(file_get_contents($graph_url));
$user holds a massive array of data....
Of course there's a lot more data handling that this script does that I haven't pasted in here, but that probably won't fit your particular application.
$app_id = "YourAppID"; $app_secret = "YourSecretID"; $my_url = "http://www.thePageThatHandlesTheData.php"; . . .Read More
Wow That's awesome!! Can you explain how you do it?? Because I want to do the same with my site and after many many hours in the facebook api, I can't achieve it. . . .Read More
no link . . .Read More
Link to anonymous blog . . .Read More
Link to facebook account . . .Read More