function user_fields
6.x user.module | user_fields() |
2 calls to user_fields()
- profile_field_form_validate in drupal-6.x/
modules/ profile/ profile.admin.inc - Validate profile_field_form submissions.
- user_save in drupal-6.x/
modules/ user/ user.module - Save changes to a user account or add a new user.
File
- drupal-6.x/
modules/ user/ user.module, line 559 - Enables the user registration and login system.
Code
function user_fields() {
static $fields;
if (!$fields) {
$result = db_query('SELECT * FROM {users} WHERE uid = 1');
if ($field = db_fetch_array($result)) {
$fields = array_keys($field);
}
else {
// Make sure we return the default fields at least.
$fields = array('uid', 'name', 'pass', 'mail', 'picture', 'mode', 'sort', 'threshold', 'theme', 'signature', 'signature_format', 'created', 'access', 'login', 'status', 'timezone', 'language', 'init', 'data');
}
}
return $fields;
}