Good morning,
after trying everything to make Facebook Connect module work, without any success, i've decided to integrate facebook API on my own.
I managed to write the code for facebook related login/logout but i don't know how to implement it with drupal authentication.

Is there a function or something to call during facebook login to automatically log into drupal site too? or is there a way to put my facebook login code into drupal one?

the code (after calling facebook class):

function facebook-access() {
  if($facebook) {
    if ($uid==0) {
      $url = $facebook -> getLoginUrl($loginParams);
    }
    else {
      $url = $facebook -> getLogoutUrl($logoutParams);
    }
  return $url;
  }
}

Comments

shadcn’s picture