Bug #8431: Remove last instances of Horde_Auth::getLoginScreen()
authorMichael M Slusarz <slusarz@curecanti.org>
Thu, 25 Feb 2010 16:43:53 +0000 (09:43 -0700)
committerMichael M Slusarz <slusarz@curecanti.org>
Thu, 25 Feb 2010 16:43:53 +0000 (09:43 -0700)
horde/services/changepassword.php
horde/services/resetpassword.php
horde/signup.php

index 3291292..4fb8b60 100644 (file)
@@ -15,7 +15,7 @@ Horde_Registry::appInit('horde', array('nologintasks' => true));
 $auth = Horde_Auth::singleton($conf['auth']['driver']);
 if (!$auth->hasCapability('update')) {
     $notification->push(_("Changing your password is not supported with the current configuration.  Contact your administrator."), 'horde.error');
-    header('Location: ' . Horde_Auth::getLoginScreen('', Horde_Util::getFormData('url')));
+    header('Location: ' . Horde::getServiceLink('login')->add('url', Horde_Util::getFormData('url'))->setRaw(true));
     exit;
 }
 
index a90d555..e1b334b 100644 (file)
@@ -15,7 +15,7 @@ Horde_Registry::appInit('horde', array('authentication' => 'none'));
 $auth = Horde_Auth::singleton($conf['auth']['driver']);
 if (!$auth->hasCapability('resetpassword')) {
     $notification->push(_("Cannot reset password automatically, contact your administrator."), 'horde.error');
-    header('Location: ' . Horde_Auth::getLoginScreen('', Horde_Util::getFormData('url')));
+    header('Location: ' . Horde::getServiceLink('login')->add('url', Horde_Util::getFormData('url'))->setRaw(true));
     exit;
 }
 
@@ -79,7 +79,7 @@ if ($can_validate && $form->validate($vars)) {
         try {
             $mail->send(Horde::getMailerConfig());
             $notification->push(_("Your password has been reset, check your email and log in with your new password."), 'horde.success');
-            header('Location: ' . Horde_Auth::getLoginScreen('', $info['url']));
+            header('Location: ' . Horde::getServiceLink('login')->add('url', $info['url'])->setRaw(true));
             exit;
         } catch (Horde_Exception $e) {
             Horde::logMessage($e, __FILE__, __LINE__, PEAR_LOG_ERR);
index 8bf0ebd..f689922 100644 (file)
@@ -17,7 +17,7 @@ $auth = Horde_Auth::singleton($conf['auth']['driver']);
 if ($conf['signup']['allow'] !== true ||
     !$auth->hasCapability('add')) {
     $notification->push(_("User Registration has been disabled for this site."), 'horde.error');
-    header('Location: ' . Horde_Auth::getLoginScreen());
+    header('Location: ' . Horde::getServiceLink('login')->setRaw(true));
     exit;
 }
 
@@ -25,7 +25,7 @@ $signup = Horde_Auth_Signup::factory();
 if (is_a($signup, 'PEAR_Error')) {
     Horde::logMessage($signup->getMessage(), __FILE__, __LINE__, PEAR_LOG_ERR);
     $notification->push(_("User Registration is not properly configured for this site."), 'horde.error');
-    header('Location: ' . Horde_Auth::getLoginScreen());
+    header('Location: ' . Horde::getServiceLink('login')->setRaw(true));
     exit;
 }
 
@@ -56,8 +56,7 @@ if ($formsignup->validate()) {
         $notification->push(sprintf(_("There was a problem adding \"%s\" to the system: %s"), $info['user_name'], $success->getMessage()), 'horde.error');
     } else {
         $notification->push($success_message, 'horde.success');
-        $url = Horde_Auth::getLoginScreen('', $info['url']);
-        header('Location: ' . $url);
+        header('Location: ' . Horde::getServiceLink('login')->add('url', $info['url'])->setRaw(true));
         exit;
     }
 }