summaryrefslogtreecommitdiff
path: root/modules/user
diff options
context:
space:
mode:
Diffstat (limited to 'modules/user')
-rw-r--r--modules/user/user.admin.inc26
-rw-r--r--modules/user/user.module8
-rw-r--r--modules/user/user.pages.inc6
3 files changed, 20 insertions, 20 deletions
diff --git a/modules/user/user.admin.inc b/modules/user/user.admin.inc
index 36bca54e0..cc488e703 100644
--- a/modules/user/user.admin.inc
+++ b/modules/user/user.admin.inc
@@ -49,10 +49,10 @@ function user_filter_form() {
$options = $type == 'permission' ? call_user_func_array('array_merge', $filters[$type]['options']) : $filters[$type]['options'];
$params = array('%property' => $filters[$type]['title'] , '%value' => $options[$value]);
if ($i++ > 0) {
- $form['filters']['current'][] = array('#value' => t('<em>and</em> where <strong>%property</strong> is <strong>%value</strong>', $params));
+ $form['filters']['current'][] = array('#markup' => t('<em>and</em> where <strong>%property</strong> is <strong>%value</strong>', $params));
}
else {
- $form['filters']['current'][] = array('#value' => t('<strong>%property</strong> is <strong>%value</strong>', $params));
+ $form['filters']['current'][] = array('#markup' => t('<strong>%property</strong> is <strong>%value</strong>', $params));
}
}
@@ -171,24 +171,24 @@ function user_admin_account() {
$accounts = array();
while ($account = db_fetch_object($result)) {
$accounts[$account->uid] = '';
- $form['name'][$account->uid] = array('#value' => theme('username', $account));
- $form['status'][$account->uid] = array('#value' => $status[$account->status]);
+ $form['name'][$account->uid] = array('#markup' => theme('username', $account));
+ $form['status'][$account->uid] = array('#markup' => $status[$account->status]);
$users_roles = array();
$roles_result = db_query('SELECT rid FROM {users_roles} WHERE uid = %d', $account->uid);
while ($user_role = db_fetch_object($roles_result)) {
$users_roles[] = $roles[$user_role->rid];
}
asort($users_roles);
- $form['roles'][$account->uid][0] = array('#value' => theme('item_list', $users_roles));
- $form['member_for'][$account->uid] = array('#value' => format_interval(time() - $account->created));
- $form['last_access'][$account->uid] = array('#value' => $account->access ? t('@time ago', array('@time' => format_interval(time() - $account->access))) : t('never'));
- $form['operations'][$account->uid] = array('#value' => l(t('edit'), "user/$account->uid/edit", array('query' => $destination)));
+ $form['roles'][$account->uid][0] = array('#markup' => theme('item_list', $users_roles));
+ $form['member_for'][$account->uid] = array('#markup' => format_interval(time() - $account->created));
+ $form['last_access'][$account->uid] = array('#markup' => $account->access ? t('@time ago', array('@time' => format_interval(time() - $account->access))) : t('never'));
+ $form['operations'][$account->uid] = array('#markup' => l(t('edit'), "user/$account->uid/edit", array('query' => $destination)));
}
$form['accounts'] = array(
'#type' => 'checkboxes',
'#options' => $accounts
);
- $form['pager'] = array('#value' => theme('pager', NULL, 50, 0));
+ $form['pager'] = array('#markup' => theme('pager', NULL, 50, 0));
return $form;
}
@@ -513,7 +513,7 @@ function user_admin_perm($form_state, $rid = NULL) {
foreach (module_list(FALSE, FALSE, TRUE) as $module) {
if ($permissions = module_invoke($module, 'perm')) {
$form['permission'][] = array(
- '#value' => $module,
+ '#markup' => $module,
);
ksort($permissions);
foreach ($permissions as $perm => $description) {
@@ -525,7 +525,7 @@ function user_admin_perm($form_state, $rid = NULL) {
$options[$perm] = '';
$form['permission'][$perm] = array(
'#type' => 'item',
- '#value' => t($perm),
+ '#markup' => t($perm),
'#description' => $hide_descriptions ? $description : NULL,
);
foreach ($role_names as $rid => $name) {
@@ -541,7 +541,7 @@ function user_admin_perm($form_state, $rid = NULL) {
// Have to build checkboxes here after checkbox arrays are built
foreach ($role_names as $rid => $name) {
$form['checkboxes'][$rid] = array('#type' => 'checkboxes', '#options' => $options, '#default_value' => isset($status[$rid]) ? $status[$rid] : array());
- $form['role_names'][$rid] = array('#value' => $name, '#tree' => TRUE);
+ $form['role_names'][$rid] = array('#markup' => $name, '#tree' => TRUE);
}
$form['submit'] = array('#type' => 'submit', '#value' => t('Save permissions'));
@@ -740,7 +740,7 @@ function theme_user_admin_account($form) {
}
$output .= theme('table', $header, $rows);
- if ($form['pager']['#value']) {
+ if ($form['pager']['#markup']) {
$output .= drupal_render($form['pager']);
}
diff --git a/modules/user/user.module b/modules/user/user.module
index 0941b0ac8..1c19fcbc1 100644
--- a/modules/user/user.module
+++ b/modules/user/user.module
@@ -653,7 +653,7 @@ function user_user($type, &$edit, &$account, $category = NULL) {
$account->content['summary']['member_for'] = array(
'#type' => 'user_profile_item',
'#title' => t('Member for'),
- '#value' => format_interval(time() - $account->created),
+ '#markup' => format_interval(time() - $account->created),
);
}
if ($type == 'form' && $category == 'account') {
@@ -701,7 +701,7 @@ function user_login_block() {
$items[] = l(t('Create new account'), 'user/register', array('attributes' => array('title' => t('Create a new user account.'))));
}
$items[] = l(t('Request new password'), 'user/password', array('attributes' => array('title' => t('Request new password via e-mail.'))));
- $form['links'] = array('#value' => theme('item_list', $items));
+ $form['links'] = array('#markup' => theme('item_list', $items));
return $form;
}
@@ -1493,7 +1493,7 @@ function user_edit_form(&$form_state, $uid, $edit, $register = FALSE) {
$form['picture'] = array('#type' => 'fieldset', '#title' => t('Picture'), '#weight' => 1);
$picture = theme('user_picture', (object)$edit);
if ($edit['picture']) {
- $form['picture']['current_picture'] = array('#value' => $picture);
+ $form['picture']['current_picture'] = array('#markup' => $picture);
$form['picture']['picture_delete'] = array('#type' => 'checkbox', '#title' => t('Delete picture'), '#description' => t('Check this box to delete your current picture.'));
}
else {
@@ -2335,7 +2335,7 @@ function user_register() {
// Display the registration form.
if (!$admin) {
- $form['user_registration_help'] = array('#value' => filter_xss_admin(variable_get('user_registration_help', '')));
+ $form['user_registration_help'] = array('#markup' => filter_xss_admin(variable_get('user_registration_help', '')));
}
// Merge in the default user edit fields.
diff --git a/modules/user/user.pages.inc b/modules/user/user.pages.inc
index 8a32f87c4..3213208a2 100644
--- a/modules/user/user.pages.inc
+++ b/modules/user/user.pages.inc
@@ -105,8 +105,8 @@ function user_pass_reset(&$form_state, $uid, $timestamp, $hashed_pass, $action =
drupal_goto('user/' . $user->uid . '/edit');
}
else {
- $form['message'] = array('#value' => t('<p>This is a one-time login for %user_name and will expire on %expiration_date.</p><p>Click on this button to login to the site and change your password.</p>', array('%user_name' => $account->name, '%expiration_date' => format_date($timestamp + $timeout))));
- $form['help'] = array('#value' => '<p>' . t('This login can be used only once.') . '</p>');
+ $form['message'] = array('#markup' => t('<p>This is a one-time login for %user_name and will expire on %expiration_date.</p><p>Click on this button to login to the site and change your password.</p>', array('%user_name' => $account->name, '%expiration_date' => format_date($timestamp + $timeout))));
+ $form['help'] = array('#markup' => '<p>' . t('This login can be used only once.') . '</p>');
$form['submit'] = array('#type' => 'submit', '#value' => t('Log in'));
$form['#action'] = url("user/reset/$uid/$timestamp/$hashed_pass/login");
return $form;
@@ -186,7 +186,7 @@ function template_preprocess_user_profile(&$variables) {
*/
function template_preprocess_user_profile_item(&$variables) {
$variables['title'] = $variables['element']['#title'];
- $variables['value'] = $variables['element']['#value'];
+ $variables['value'] = $variables['element']['#markup'];
$variables['attributes'] = '';
if (isset($variables['element']['#attributes'])) {
$variables['attributes'] = drupal_attributes($variables['element']['#attributes']);