diff --git a/login_destination.admin.inc b/login_destination.admin.inc index 3616c5b..c18dc43 100755 --- a/login_destination.admin.inc +++ b/login_destination.admin.inc @@ -96,7 +96,7 @@ function theme_login_destination_triggers($variables) { function theme_login_destination_pages($variables) { $type = $variables['pages_type']; - + if ($type == LOGIN_DESTINATION_REDIRECT_PHP) { return nl2br(check_plain($variables['pages'])); } @@ -120,7 +120,7 @@ function theme_login_destination_pages($variables) { $output .= "~ "; } $output .= $page . "
"; - } + } return $output; } @@ -178,7 +178,7 @@ function login_destination_edit_form($form, &$form_state, array $rule = array()) $form['destination_type'] = array( '#type' => 'radios', - '#title' => 'Redirect to page', + '#title' => t('Redirect to page'), '#default_value' => $type, '#options' => $options, ); @@ -197,7 +197,7 @@ function login_destination_edit_form($form, &$form_state, array $rule = array()) $form['triggers'] = array( '#type' => 'checkboxes', '#title' => t('Redirect upon triggers'), - '#options' => array('login' => 'Login, registration, one-time login link', 'logout' => 'Logout'), + '#options' => array('login' => t('Login, registration, one-time login link'), 'logout' => t('Logout')), '#default_value' => $triggers, '#description' => t('Redirect only upon selected trigger(s). If you select no triggers, all of them will be used.'), ); @@ -296,7 +296,7 @@ function login_destination_edit_form_submit($form, &$form_state) { } drupal_set_message(t('Login destination to %destination has been saved.', array('%destination' => $form_state['values']['destination']))); - + $form_state['redirect'] = 'admin/config/people/login-destination'; } diff --git a/login_destination.module b/login_destination.module index 2ad4262..3c7940b 100644 --- a/login_destination.module +++ b/login_destination.module @@ -102,7 +102,7 @@ function login_destination_load($id) { if (empty($result['roles'])) { $result['roles'] = array(); } - + return $result; } @@ -187,14 +187,14 @@ function login_destination_validate($form, &$form_state) { } break; } - + // Fix the current page in case of 403 page. if ($form['#form_id'] == 'user_login') { if(drupal_get_http_header('Status') == '403 Forbidden') { $_GET['current'] = $_GET['destination']; } } - + } /**