1 user.api.php hook_user_login_paths()

Define paths related to the user login process.

The paths "user/login", "user/password", and "user/register" are added by User module. Other modules that expand the user login process should also add their paths here.

Return value

array: For each item, the key is the path in question, in a format acceptable to backdrop_match_path(). The value for each item should be TRUE (for paths related to the login process) or FALSE (for non-login related paths).

See also

hook_menu()

backdrop_match_path()

hook_user_login_paths_alter()

Related topics

File

core/modules/user/user.api.php, line 447
Hooks provided by the User module.

Code

function hook_user_login_paths() {
  return array(
    'my_module/user/login' => TRUE,
    'my_module/user/password' => TRUE,
    'my_module/user/login/*' => TRUE,
  );
}