function user_page

Same name and namespace in other branches
  1. 6.x drupal-6.x/modules/user/user.pages.inc \user_page()

Page callback: Displays the user page.

Displays user profile if user is logged in, or login form for anonymous users.

Return value

A render array for either a user profile or a login form.

See also

user_view_page()

user_login()

3 string references to 'user_page'
drupal-6.bare.database.php in drupal-7.x/modules/simpletest/tests/upgrade/drupal-6.bare.database.php
Bare installation of Drupal 6.17, for test purposes.
drupal-6.filled.database.php in drupal-7.x/modules/simpletest/tests/upgrade/drupal-6.filled.database.php
Filled installation of Drupal 6.17, for test purposes.
user_menu in drupal-7.x/modules/user/user.module
Implements hook_menu().

Archivo

drupal-7.x/modules/user/user.pages.inc, line 552
User page callback file for the user module.

Código

function user_page() {
  global $user;
  if ($user->uid) {
    menu_set_active_item('user/' . $user->uid);
    return menu_execute_active_handler(NULL, FALSE);
  }
  else {
    return drupal_get_form('user_login');
  }
}