--- logintoboggan.module	2009-06-30 16:16:20.000000000 -0500
+++ logintoboggan.module.new	2009-06-22 17:08:37.000000000 -0500
@@ -738,6 +738,13 @@ function logintoboggan_main_settings(&$f
     '#description' => t('Normally, after a user confirms their new account, they will be taken to their user page. Leave this setting blank if you wish to keep the default behavior. If you wish the user to go to a page of your choosing, then enter the path for it here. For instance, you may redirect them to a static page such as <cite>node/35</cite>, or to the <cite>&lt;front&gt;</cite> page. You may also use <em>%uid</em> as a variable, and the user\'s user ID will be substituted in the path. In the case where users are not creating their own passwords, it is suggested to use <cite>user/%uid/edit</cite> here, so the user may set their password immediately after validating their account.'),
   );
 
+$form['registration']['redirect']['logintoboggan_redirect_on_login'] = array(
+    '#type' => 'textfield',
+    '#title' => t('Redirect path on Login'),
+    '#default_value' => variable_get('logintoboggan_redirect_on_login', ''),
+    '#description' => t('Normally, a user is not redirected when they log in. If you add a path here, a user will be redirected to it.'),
+  );
+  
   $form['other'] = array('#type' => 'fieldset',
     '#title' => t('Other'),
     '#tree' => FALSE,
@@ -1052,6 +1059,8 @@ function logintoboggan_user($op, &$edit,
     }
   } elseif ($op == 'login' && variable_get('logintoboggan_login_successful_message', 0)) {
     drupal_set_message(theme('lt_login_successful_message', $user_edit));
+	  $redirect = variable_get('logintoboggan_redirect_on_login', '');
+	  if($redirect) { $_REQUEST['destination'] = $redirect; }
   }
   elseif ($op == 'load') {
     // Just loaded the user into $user_edit.
