You are here

function gravatar_form_comment_form_alter in Gravatar integration 6

Same name and namespace in other branches
  1. 7 gravatar.module \gravatar_form_comment_form_alter()

Implements hook_form_FORM_ID_alter().

@todo Improve message shown to user.

File

./gravatar.module, line 232
Integrates gravatar service for user pictures.

Code

function gravatar_form_comment_form_alter(&$form, $form_state) {
  if (isset($form['mail']) && user_access('use gravatar', drupal_anonymous_user())) {
    $form['mail']['#description'] .= ' ' . t('If you have a <a href="@gravatar-website">Gravatar</a> account associated with the e-mail address you provide, it will be used to display your avatar.', array(
      '@gravatar-website' => url('http://www.gravatar.com/'),
    ));
  }
}