You are here

function logintoboggan_get_authentication_form in LoginToboggan 7

Returns an appropriate authentication form based on the configuration.

Parameters

$active_form: Which form to display, should be 'login' or 'register'.

1 call to logintoboggan_get_authentication_form()
logintoboggan_unified_login_page in ./logintoboggan.module
Menu callback for user/login creates a unified login/registration form (without tabs)

File

./logintoboggan.module, line 938
LoginToboggan module

Code

function logintoboggan_get_authentication_form($active_form = 'login') {
  $output = '';
  if (variable_get('logintoboggan_unified_login', 0)) {
    $output = logintoboggan_unified_login_form($active_form);
  }
  elseif ($active_form == 'login') {
    $output = drupal_get_form('user_login');
  }
  elseif ($active_form == 'register') {
    $output = drupal_get_form('user_register_form');
  }
  return $output;
}