adj 2007-11-30 13:27
修改 openwebmail 介面空間用量的百分比...
修改檔案為:openwebmail-folder.pl 第206、209行
my $usagestr;
if ($config{'quota_module'} ne "none") {
my $percent=0;
my $allquota=0;
my $oldquota=0;
$oldquota=`sudo /usr/bin/du -sk $homedir/mail | cut -d "\" -f1`;
$allquota=$quotausage*1024+$total_foldersize-$oldquota*1024;
$usagestr="$lang_text{'quotausage'}: ".lenstr($allquota);
#$usagestr="$lang_text{'quotausage'}: ".lenstr($quotausage*1024,1);
if ($quotalimit>0) {
$percent=int($allquota/$quotalimit)/10;
# $percent=int($quotausage*1000/$quotalimit)/10;
$usagestr.=" ($percent%) ";
$usagestr.="$lang_text{'quotalimit'}: ".lenstr($quotalimit*1024,1);
}
if ($percent>=90) {
$usagestr="<B><font color='#cc0000'>$usagestr</font></B>";
} else {
$usagestr="<B>$usagestr</B>";
}
} else {
$usagestr=" ";
}
$total_foldersize=lenstr($total_foldersize,0);