You are here

function invite_load_from_session in Invite 6.2

Same name and namespace in other branches
  1. 5.2 invite.module \invite_load_from_session()
  2. 5 invite.module \invite_load_from_session()
  3. 7.4 invite.module \invite_load_from_session()

Returns an invite record from an invite code stored in the user's session.

Return value

An invite record, or FALSE if there is no invite code stored in the user's session.

3 calls to invite_load_from_session()
invite_form_alter in ./invite.module
Implementation of hook_form_alter().
invite_user in ./invite.module
Implementation of hook_user().
invite_user_register_access in ./invite.module
Access callback; determine access to user registration form.

File

./invite.module, line 424
Allows your users to send and track invitations to join your site.

Code

function invite_load_from_session() {
  if (isset($_SESSION[INVITE_SESSION])) {
    return invite_load($_SESSION[INVITE_SESSION]);
  }
  return FALSE;
}