diff options
Diffstat (limited to 'modules/profile')
-rw-r--r-- | modules/profile/profile.js | 2 | ||||
-rw-r--r-- | modules/profile/profile.module | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/modules/profile/profile.js b/modules/profile/profile.js index f842aa08a..f262560d2 100644 --- a/modules/profile/profile.js +++ b/modules/profile/profile.js @@ -24,7 +24,7 @@ Drupal.behaviors.profileDrag = { } } // This category has become empty - if ($(this).next('tr').is(':not(.draggable)') || $(this).next('tr').size() == 0) { + if ($(this).next('tr').is(':not(.draggable)') || $(this).next('tr').length == 0) { $(this).removeClass('category-populated').addClass('category-empty'); } // This category has become populated. diff --git a/modules/profile/profile.module b/modules/profile/profile.module index 132e43889..6b00d4296 100644 --- a/modules/profile/profile.module +++ b/modules/profile/profile.module @@ -33,7 +33,7 @@ function profile_help($path, $arg) { case 'admin/help#profile': $output = ''; $output .= '<h3>' . t('About') . '</h3>'; - $output .= '<p>' . t('The Profile module allows site administrators to define custom fields (such as country, full name, or age) for user profiles, which are then displayed in the <a href="@user">My Account</a> section. This permits users of a site to share more information about themselves, and can help community-based sites organize users around specific information. For more information, see the online handbook entry for <a href="@profile">Profile module</a>.', array('@user' => url('user'), '@profile' => 'http://drupal.org/handbook/modules/profile/')) . '</p>'; + $output .= '<p>' . t('The Profile module allows site administrators to define custom fields (such as country, full name, or age) for user profiles, which are then displayed in the <a href="@user">My Account</a> section. This permits users of a site to share more information about themselves, and can help community-based sites organize users around specific information. For more information, see the online handbook entry for <a href="@profile">Profile module</a>.', array('@user' => url('user'), '@profile' => 'http://drupal.org/documentation/modules/profile/')) . '</p>'; $output .= '<h3>' . t('Uses') . '</h3>'; $output .= '<dl>'; $output .= '<dt>' . t('Adding fields to the default profile') . '</dt>'; @@ -435,7 +435,7 @@ function profile_form_alter(&$form, &$form_state, $form_id) { break; case 'selection': - $options = $field->required ? array() : array('--'); + $options = array(); $lines = preg_split("/[\n\r]/", $field->options); foreach ($lines as $line) { if ($line = trim($line)) { @@ -449,6 +449,7 @@ function profile_form_alter(&$form, &$form_state, $form_id) { '#options' => $options, '#description' => _profile_form_explanation($field), '#required' => $field->required, + '#empty_value' => 0, ); break; |