You are here

function fb_user_token_values in Drupal for Facebook 6.2

Same name and namespace in other branches
  1. 5.2 fb_user.module \fb_user_token_values()
  2. 5 fb_user.module \fb_user_token_values()
  3. 6.3 fb_user.module \fb_user_token_values()
  4. 7.3 fb_user.module \fb_user_token_values()

File

./fb_user.module, line 854
This module manages relations between local Drupal user accounts and their accounts on facebook.com.

Code

function fb_user_token_values($type = 'all', $object = NULL) {
  $values = array();
  if ($type == 'fb_app' && $object) {
    $fb_app = $object;
    global $user;
    $fbu = _fb_user_get_fbu($user->uid, $fb_app);
    if ($fbu) {
      $values['fb-app-user-fbu'] = $fbu;
      $values['fb-app-user-name'] = 'TODO XXX';

      // XXX
      $values['fb-app-user-name-fbml'] = '<fb:name uid="' . $fbu . '" />';
      $values['fb-app-profile-url'] = 'http://www.facebook.com/profile.php?id=' . $fbu;
    }
  }
  return $values;
}