version 1.16, 2003/08/05 18:33:08
|
version 1.19, 2003/08/20 01:34:25
|
Line 26 my $fromcache;
|
Line 26 my $fromcache;
|
my %domaindescription = (); |
my %domaindescription = (); |
my %domain_auth_def = (); |
my %domain_auth_def = (); |
my %domain_auth_arg_def = (); |
my %domain_auth_arg_def = (); |
|
my %domain_lang_def=(); |
|
my %domain_city=(); |
|
my %domain_longi=(); |
|
my %domain_lati=(); |
|
|
my %hostname=(); |
my %hostname=(); |
my %hostip=(); |
my %hostip=(); |
Line 212 sub server {
|
Line 216 sub server {
|
print &otherwindow($local,'/server-status','Server Status'); |
print &otherwindow($local,'/server-status','Server Status'); |
} |
} |
|
|
|
sub announcement { |
|
my $local=shift; |
|
print &otherwindow($local,'/announcement.txt','Announcement'); |
|
} |
|
|
# ========================================================= Produce a green bar |
# ========================================================= Produce a green bar |
sub bar { |
sub bar { |
my $parm=shift; |
my $parm=shift; |
Line 233 sub serverstatus {
|
Line 242 sub serverstatus {
|
<tr><td bgcolor="#BBDDBB"><font color="#225522" face="arial"><b> |
<tr><td bgcolor="#BBDDBB"><font color="#225522" face="arial"><b> |
$local $hostdom{$local}</b> <tt>($hostname{$local}; $hostrole{$local})</tt> |
$local $hostdom{$local}</b> <tt>($hostname{$local}; $hostrole{$local})</tt> |
<br />$domaindescription{$hostdom{$local}} |
<br />$domaindescription{$hostdom{$local}} |
|
$domain_city{$hostdom{$local}} |
</font></th></tr><tr><td bgcolor="#DDDDBB"><font color="#225522"> |
</font></th></tr><tr><td bgcolor="#DDDDBB"><font color="#225522"> |
ENDHEADER |
ENDHEADER |
&login($local);&server($local);&users($local);&versions($local); |
&login($local);&server($local);&users($local);&versions($local); |
|
&announcement($local); |
&loncron($local);&lond($local);&lonc($local);&runloncron($local); |
&loncron($local);&lond($local);&lonc($local);&runloncron($local); |
print "</font></td></tr>"; |
print "</font></td></tr>"; |
if ($trouble) { |
if ($trouble) { |
Line 303 sub resetvars {
|
Line 314 sub resetvars {
|
$stat_total=0; |
$stat_total=0; |
$stat_notyet=0; |
$stat_notyet=0; |
$stat_fromcache=0; |
$stat_fromcache=0; |
|
$concount=0; |
undef %host; |
undef %host; |
%host=(); |
%host=(); |
} |
} |
Line 431 sub reports {
|
Line 442 sub reports {
|
"<table cellspacing='3' cellpadding='3' border='0' bgcolor='#225522'>". |
"<table cellspacing='3' cellpadding='3' border='0' bgcolor='#225522'>". |
"<tr><td bgcolor='#225522'> </td>"; |
"<tr><td bgcolor='#225522'> </td>"; |
foreach my $remote (sort keys %hostname) { |
foreach my $remote (sort keys %hostname) { |
print '<th bgcolor="#DDDDBB">'.$remote.'</th>'; |
print '<td bgcolor="#DDDDBB">'.$remote.'</td>'; |
} |
} |
print "</tr>\n"; |
print "</tr>\n"; |
# connection matrix |
# connection matrix |
foreach my $local (sort keys %hostname) { |
foreach my $local (sort keys %hostname) { |
print '<tr><th bgcolor="#DDDDBB">'.$local.'</th>'; |
print '<tr><td bgcolor="#DDDDBB">'.$local.'</td>'; |
foreach my $remote (sort keys %hostname) { |
foreach my $remote (sort keys %hostname) { |
if ($connectionstatus{$local.'_TO_'.$remote} eq 'not_yet') { |
if ($connectionstatus{$local.'_TO_'.$remote} eq 'not_yet') { |
my $cellcolor='#FFFFFF'; |
my $cellcolor='#FFFFFF'; |
Line 641 delete $perlvar{'lonSqlAccess'}; # remov
|
Line 652 delete $perlvar{'lonSqlAccess'}; # remov
|
while (<$fh>) { |
while (<$fh>) { |
next if (/^(\#|\s*$)/); |
next if (/^(\#|\s*$)/); |
chomp; |
chomp; |
my ($domain, $domain_description, $def_auth, $def_auth_arg) |
my ($domain, $domain_description, $def_auth, $def_auth_arg, |
= split(/:/,$_,4); |
$def_lang, $city, $longi, $lati) = split(/:/,$_); |
$domain_auth_def{$domain}=$def_auth; |
$domain_auth_def{$domain}=$def_auth; |
$domain_auth_arg_def{$domain}=$def_auth_arg; |
$domain_auth_arg_def{$domain}=$def_auth_arg; |
$domaindescription{$domain}=$domain_description; |
$domaindescription{$domain}=$domain_description; |
|
$domain_lang_def{$domain}=$def_lang; |
|
$domain_city{$domain}=$city; |
|
$domain_longi{$domain}=$longi; |
|
$domain_lati{$domain}=$lati; |
} |
} |
} |
} |
} |
} |