version 1.141, 2009/02/19 11:01:29
|
version 1.144, 2009/02/23 20:25:44
|
Line 1215 sub passwordchanger {
|
Line 1215 sub passwordchanger {
|
Apache::lonhtmlcommon::add_breadcrumb( |
Apache::lonhtmlcommon::add_breadcrumb( |
{ href => '/adm/preferences?action=changepass', |
{ href => '/adm/preferences?action=changepass', |
text => 'Change Password'}); |
text => 'Change Password'}); |
$r->print(Apache::loncommon::start_page('Change Password')); |
unless ($caller eq 'reset_by_email') { |
$r->print(Apache::lonhtmlcommon::breadcrumbs('Change Password')); |
$r->print(Apache::loncommon::start_page('Change Password')); |
|
$r->print(Apache::lonhtmlcommon::breadcrumbs('Change Password')); |
|
} |
if ((!defined($caller)) || ($caller eq 'preferences')) { |
if ((!defined($caller)) || ($caller eq 'preferences')) { |
$user = $env{'user.name'}; |
$user = $env{'user.name'}; |
$domain = $env{'user.domain'}; |
$domain = $env{'user.domain'}; |
Line 1552 ENDERROR
|
Line 1554 ENDERROR
|
# Inform the user the password has (not?) been changed |
# Inform the user the password has (not?) been changed |
my $message; |
my $message; |
if ($result =~ /^ok$/) { |
if ($result =~ /^ok$/) { |
$message = &mt('The password for [_1] was successfully changed',$user); |
$message = &mt('The password for [_1] was successfully changed.',$user); |
print_main_menu($r, $message); |
if ($caller eq 'reset_by_email') { |
|
$r->print($message.'<br />'); |
|
} else { |
|
&print_main_menu($r, $message); |
|
} |
# $r->print("<h3>".&mt('The password for [_1] was successfully changed',$user)."</h3>"); |
# $r->print("<h3>".&mt('The password for [_1] was successfully changed',$user)."</h3>"); |
} else { |
} else { |
# error error: run in circles, scream and shout |
# error error: run in circles, scream and shout |
$message = &mt("The password for [_1] was not changed",$user) |
$message = &mt("The password for [_1] was not changed.",$user).' '. |
.&mt('Please make sure your old password was entered correctly.'); |
.&mt('Please make sure your old password was entered correctly.'); |
print_main_menu($r, $message); |
unless ($caller eq 'reset_by_email') { |
|
&print_main_menu($r, $message); |
|
} |
# $r->print("<h3><span class='LC_error'>".&mt("The password for [_1] was not changed",$user)."</span></h3>". |
# $r->print("<h3><span class='LC_error'>".&mt("The password for [_1] was not changed",$user)."</span></h3>". |
# &mt('Please make sure your old password was entered correctly.')); |
# &mt('Please make sure your old password was entered correctly.')); |
return 1; |
return 1; |
Line 1667 END
|
Line 1675 END
|
END |
END |
$r->print(&Apache::loncommon::end_data_table_row(). |
$r->print(&Apache::loncommon::end_data_table_row(). |
&Apache::loncommon::end_data_table()); |
&Apache::loncommon::end_data_table()); |
$r->print(<<"END"); |
|
<br /> |
$r->print('<br /><br /><input type="submit" name="sub" value="'.&mt('Save').'" /><br /><br />'.&mt('Note').': '.$lt{'thde'}.'</form>'); |
<br /> |
|
<input type="submit" name="sub" value="Save" /> |
|
<br /> |
|
<br /> |
|
Note: $lt{'thde'} |
|
</form> |
|
END |
|
} |
} |
|
|
sub verify_and_change_discussion { |
sub verify_and_change_discussion { |
Line 1738 sub coursedisplaychanger {
|
Line 1739 sub coursedisplaychanger {
|
} |
} |
my %pagenames = &Apache::lonlocal::texthash( |
my %pagenames = &Apache::lonlocal::texthash( |
firstres => 'First resource', |
firstres => 'First resource', |
whatsnew => "What's New page", |
whatsnew => "What's New Page", |
); |
); |
my $whatsnew_off=&mt('Display the [_1]first resource[_2] in the course.','<b>','</b>'); |
my $whatsnew_off=&mt('Display the [_1]first resource[_2] in the course.','<b>','</b>'); |
my $whatsnew_on=&mt("Display the [_1]What's New page[_2] - a summary of items in the course which require attention.",'<b>','</b>'); |
my $whatsnew_on=&mt("Display the [_1]What's New Page[_2] - a summary of items in the course which require attention.",'<b>','</b>'); |
|
|
$r->print('<br /><b>' |
$r->print('<br /><b>' |
.&mt('Set the default page to be displayed when you select a course role') |
.&mt('Set the default page to be displayed when you select a course role') |
.'</b> ' |
.'</b> ' |
.&mt('(Currently: [_1])',$pagenames{$currvalue}) |
.&mt('(Currently: [_1])',$pagenames{$currvalue}) |
.'<br />' |
.'<br />' |
.&mt("The global user preference you set for your courses can be overridden in an individual course by setting a course specific setting via the [_1]What's New page[_2] in the course.",'<i>','</i>') |
.&mt("The global user preference you set for your courses can be overridden in an individual course by setting a course specific setting via the [_1]What's New Page[_2] in the course.",'<i>','</i>') |
.'<br /><br />' |
.'<br /><br />' |
); |
); |
$r->print(<<ENDLSCREEN); |
$r->print(<<ENDLSCREEN); |
Line 1771 sub verify_and_change_coursepage {
|
Line 1772 sub verify_and_change_coursepage {
|
'ywbt' => 'you will be taken to the start of the course.', |
'ywbt' => 'you will be taken to the start of the course.', |
'apwb' => 'a page will be displayed that lists items in the course that may require action from you.', |
'apwb' => 'a page will be displayed that lists items in the course that may require action from you.', |
'gtts' => 'Go to the start of the course', |
'gtts' => 'Go to the start of the course', |
'dasp' => "Display the What's New page listing course action items", |
'dasp' => "Display the What's New Page listing course action items", |
); |
); |
my $newdisp = $env{'form.newdisp'}; |
my $newdisp = $env{'form.newdisp'}; |
$message = '<b>'.$lt{'defs'}.'</b>: '.$lt{'when'}.', '; |
$message = '<b>'.$lt{'defs'}.'</b>: '.$lt{'when'}.', '; |