[LON-CAPA-cvs] cvs: loncom(version_2_10_X) /interface lonpreferences.pm

raeburn raeburn at source.lon-capa.org
Fri Oct 7 13:14:43 EDT 2011


raeburn		Fri Oct  7 17:14:43 2011 EDT

  Modified files:              (Branch: version_2_10_X)
    /loncom/interface	lonpreferences.pm 
  Log:
  - Backport 1.193, 1.194.
  
  
Index: loncom/interface/lonpreferences.pm
diff -u loncom/interface/lonpreferences.pm:1.186.2.6 loncom/interface/lonpreferences.pm:1.186.2.7
--- loncom/interface/lonpreferences.pm:1.186.2.6	Mon May 16 00:57:08 2011
+++ loncom/interface/lonpreferences.pm	Fri Oct  7 17:14:43 2011
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Preferences
 #
-# $Id: lonpreferences.pm,v 1.186.2.6 2011/05/16 00:57:08 raeburn Exp $
+# $Id: lonpreferences.pm,v 1.186.2.7 2011/10/07 17:14:43 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1288,7 +1288,7 @@
     # This function is a bit of a mess....
     # Passwords are encrypted using londes.js (DES encryption)
     $errormessage = ($errormessage || '');
-    my ($user,$domain,$currentpass,$defdom);
+    my ($user,$domain,$currentpass);
     &Apache::lonhtmlcommon::add_breadcrumb(
 		{ href => '/adm/preferences?action=changepass',
                   text => 'Change Password'});
@@ -1303,7 +1303,6 @@
             $caller = 'preferences';
         }
     } elsif ($caller eq 'reset_by_email') {
-            $defdom = $r->dir_config('lonDefDomain');
             my %data = &Apache::lonnet::tmpget($mailtoken);
             if (keys(%data) == 0) {
                 $r->print(&mt('Sorry, the URL you provided to complete the reset of your password was invalid. Either the token included in the URL has been deleted or the URL you provided was invalid. Please submit a [_1]new request[_2] for a password reset, and follow the link to the new URL included in the e-mail that will be sent to you, to allow you to enter a new password.'
@@ -1324,6 +1323,9 @@
                 $r->print(&mt('Sorry, the URL generated when you requested reset of your password contained incomplete information.').'<br />');
                 return;
             }
+            if (&Apache::lonnet::domain($domain) eq '') {
+                $domain = $r->dir_config('lonDefDomain');
+            }
    } else {
         $r->print(&mt('Page requested in unexpected context').'<br />');
         return;
@@ -1368,7 +1370,7 @@
      crappy browser -->
 ENDFORM
     $r->print(&server_form($logtoken,$caller,$mailtoken));
-    $r->print(&client_form($caller,\%hexkey,$currentpass,$defdom));
+    $r->print(&client_form($caller,\%hexkey,$currentpass,$domain));
 
     #
     return;
@@ -1702,13 +1704,13 @@
         'sdpf' => 'Set display preferences for discussion posts for both discussion boards and individual resources in all your courses.',
         'prca' => 'Preferences can be set that determine',
         'whpo' => 'Which posts are displayed when you display a discussion board or resource, and',
-        'unwh' => 'Under what circumstances posts are identfied as "New"',
+        'unwh' => 'Under what circumstances posts are identfied as "NEW"',
         'allposts' => 'All posts',
         'unread' => 'New posts only',
         'ondisp' => 'Once displayed',
-        'onmark' => 'Once marked as read',
+        'onmark' => 'Once marked not NEW',
         'disa' => 'Posts displayed?',
-        'npmr' => 'New posts cease to be identified as "New"?',
+        'npmr' => 'New posts cease to be identified as "NEW"?',
         'thde'  => 'The preferences you set here can be overridden within each individual discussion.',
         'chgt' => 'Change to '
     );
@@ -1793,7 +1795,7 @@
             &Apache::lonnet::put('environment',{'discmarkread' => $newmark});
             &Apache::lonnet::appenv({'environment.discmarkread' => $newmark});
         } else {
-            $message.=&Apache::lonhtmlcommon::confirm_success(&mt('In discussions: posts will be identified as "NEW" until marked as read by the reader.')).'<br />';
+            $message.=&Apache::lonhtmlcommon::confirm_success(&mt('In discussions: posts will be identified as "NEW" until marked as not "NEW".')).'<br />';
             &Apache::lonnet::del('environment',['discmarkread']);
             &Apache::lonnet::delenv('environment.discmarkread');
         }




More information about the LON-CAPA-cvs mailing list