version 1.425, 2023/06/03 19:18:11
|
version 1.426, 2023/06/03 19:26:31
|
Line 6782 sub ltimenu_titles {
|
Line 6782 sub ltimenu_titles {
|
); |
); |
} |
} |
|
|
sub check_switchserver { |
|
my ($home) = @_; |
|
my $switchserver; |
|
if ($home ne '') { |
|
my $allowed; |
|
my @ids=&Apache::lonnet::current_machine_ids(); |
|
foreach my $id (@ids) { if ($id eq $home) { $allowed=1; } } |
|
if (!$allowed) { |
|
$switchserver='<a href="/adm/switchserver?otherserver='.$home.'&role='. |
|
&HTML::Entities::encode($env{'request.role'},'\'<>"&'). |
|
'&destinationurl=/adm/domainprefs">'.&mt('Switch Server').'</a>'; |
|
} |
|
} |
|
return $switchserver; |
|
} |
|
|
|
sub print_coursedefaults { |
sub print_coursedefaults { |
my ($position,$dom,$settings,$rowtotal) = @_; |
my ($position,$dom,$settings,$rowtotal) = @_; |
my ($css_class,$datatable,%checkedon,%checkedoff,%defaultchecked,@toggles); |
my ($css_class,$datatable,%checkedon,%checkedoff,%defaultchecked,@toggles); |
Line 11715 sub modifiable_userdata_row {
|
Line 11699 sub modifiable_userdata_row {
|
'<td class="LC_left_item" colspan="2"><table>'; |
'<td class="LC_left_item" colspan="2"><table>'; |
my $rem; |
my $rem; |
my %checks; |
my %checks; |
my %current; |
|
if (ref($settings) eq 'HASH') { |
if (ref($settings) eq 'HASH') { |
my $hashref; |
my $hashref; |
if ($context eq 'lti') { |
if ($context eq 'lti') { |
Line 13492 sub check_switchserver {
|
Line 13475 sub check_switchserver {
|
my @ids=&Apache::lonnet::current_machine_ids(); |
my @ids=&Apache::lonnet::current_machine_ids(); |
foreach my $id (@ids) { if ($id eq $home) { $allowed=1; } } |
foreach my $id (@ids) { if ($id eq $home) { $allowed=1; } } |
if (!$allowed) { |
if (!$allowed) { |
$switchserver='<a href="/adm/switchserver?otherserver='.$home.'&role=dc./'.$dom.'/&destinationurl=/adm/domainprefs">'.&mt('Switch Server').'</a>'; |
$switchserver='<a href="/adm/switchserver?otherserver='.$home.'&role='. |
|
&HTML::Entities::encode($env{'request.role'},'\'<>"&'). |
|
'&destinationurl=/adm/domainprefs">'.&mt('Switch Server').'</a>'; |
} |
} |
return $switchserver; |
return $switchserver; |
} |
} |