From 81938a3cdc7b9bd13d58e355c59d9835e830fea4 Mon Sep 17 00:00:00 2001 From: Steven Wittens Date: Fri, 18 Aug 2006 12:17:00 +0000 Subject: #76802: Introduce placeholder magic into t() See: http://drupal.org/node/64279#t-placeholders --- modules/profile/profile.module | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'modules/profile/profile.module') diff --git a/modules/profile/profile.module b/modules/profile/profile.module index a0f57a6dd..4ec71d4f1 100644 --- a/modules/profile/profile.module +++ b/modules/profile/profile.module @@ -34,11 +34,11 @@ function profile_help($section) { '); $output .= t('

You can

', array('%profile' => url('profile'), '%admin-settings-profile' => url('admin/user/profile'))); - $output .= '

'. t('For more information please read the configuration and customization handbook Profile page.', array('%profile' => 'http://drupal.org/handbook/modules/profile/')) .'

'; + $output .= '

'. t('For more information please read the configuration and customization handbook Profile page.', array('@profile' => 'http://drupal.org/handbook/modules/profile/')) .'

'; return $output; case 'admin/settings/modules#description': return t('Supports configurable user profiles.'); @@ -116,7 +116,7 @@ function profile_block($op = 'list', $delta = 0, $edit = array()) { '#title' => t('Profile fields to display'), '#default_value' => variable_get('profile_block_author_fields', NULL), '#options' => $fields, - '#description' => t('Select which profile fields you wish to display in the block. Only fields designated as public in the profile field configuration are available.', array('%profile-admin' => url('admin/user/profile'))), + '#description' => t('Select which profile fields you wish to display in the block. Only fields designated as public in the profile field configuration are available.', array('@profile-admin' => url('admin/user/profile'))), ); return $form; } @@ -367,7 +367,7 @@ function profile_field_delete($fid) { $form['fid'] = array('#type' => 'value', '#value' => $fid); $form['title'] = array('#type' => 'value', '#value' => $field->title); - return confirm_form('profile_field_delete', $form, t('Are you sure you want to delete the field %field?', array('%field' => theme('placeholder', $field->title))), 'admin/user/profile', t('This action cannot be undone. If users have entered values into this field in their profile, these entries will also be deleted. If you want to keep the user-entered data, instead of deleting the field you may wish to edit this field and change it to a %hidden-field so that it may only be accessed by administrators.', array('%edit-field' => url('admin/user/profile/edit/' . $fid), '%hidden-field' => theme('placeholder', t('hidden profile field')))), t('Delete'), t('Cancel')); + return confirm_form('profile_field_delete', $form, t('Are you sure you want to delete the field %field?', array('%field' => $field->title)), 'admin/user/profile', t('This action cannot be undone. If users have entered values into this field in their profile, these entries will also be deleted. If you want to keep the user-entered data, instead of deleting the field you may wish to edit this field and change it to a hidden profile field so that it may only be accessed by administrators.', array('@edit-field' => url('admin/user/profile/edit/' . $fid))), t('Delete'), t('Cancel')); } /** @@ -379,8 +379,8 @@ function profile_field_delete_submit($form_id, $form_values) { cache_clear_all(); - drupal_set_message(t('The field %field has been deleted.', array('%field' => theme('placeholder', $form_values['title'])))); - watchdog('profile', t('Profile field %field deleted.', array('%field' => theme('placeholder', $form_values['title']))), WATCHDOG_NOTICE, l(t('view'), 'admin/user/profile')); + drupal_set_message(t('The field %field has been deleted.', array('%field' => $form_values['title']))); + watchdog('profile', t('Profile field %field deleted.', array('%field' => $form_values['title'])), WATCHDOG_NOTICE, l(t('view'), 'admin/user/profile')); return 'admin/user/profile'; } @@ -757,12 +757,12 @@ function profile_validate_profile($edit, $category) { if ($edit[$field->name]) { if ($field->type == 'url') { if (!valid_url($edit[$field->name], TRUE)) { - form_set_error($field->name, t('The value provided for %field is not a valid URL.', array('%field' => theme('placeholder', $field->title)))); + form_set_error($field->name, t('The value provided for %field is not a valid URL.', array('%field' => $field->title))); } } } else if ($field->required && !user_access('administer users')) { - form_set_error($field->name, t('The field %field is required.', array('%field' => theme('placeholder', $field->title)))); + form_set_error($field->name, t('The field %field is required.', array('%field' => $field->title))); } } -- cgit v1.2.3