Popular Articles
martes, 10 de marzo de 2015
codigo prueba facebook
'661852170590178',
'secret' => 'fc1e30e59bda70f9d8ad51f080e75362',
));
// Get User ID
$user = $facebook->getUser();
// We may or may not have this data based on whether the user is logged in.
//
// If we have a $user id here, it means we know the user is logged into
// Facebook, but we don't know if the access token is valid. An access
// token is invalid if the user logged out of Facebook.
if ($user) {
try {
// Proceed knowing you have a logged in user who's authenticated.
$user_profile = $facebook->api('/me');
} catch (FacebookApiException $e) {
error_log($e);
$user = null;
}
}
// Login or logout url will be needed depending on current user state.
if ($user) {
$logoutUrl = $facebook->getLogoutUrl();
} else {
$loginUrl = $facebook->getLoginUrl();
}
// This call will always work since we are fetching public data.
$naitik = $facebook->api('/naitik');
?>
php-sdk
php-sdk
Logout
Login using OAuth 2.0 handled by the PHP SDK:
Login with Facebook
PHP Session
You
Your User Object (/me)
You are not Connected.Public profile of Naitik
Suscribirse a:
Enviar comentarios (Atom)
No hay comentarios:
Publicar un comentario