/********************************
四葉の芽画像掲示板
-yotsubanome.php*/$ver = "v0.7.8.1.0002 β lot.100404";/*
+yotsubanome.php*/$ver = "v0.7.8.1.0004 β lot.100404";/*
これがコアシステムです。 四葉の芽スクリプト
このスクリプトはレッツPHP!<http://php.s3.to/>のgazou.phpを改造したものです。
說明條目可資參考。
*/
-//error_reporting(E_ALL); // show all errors for debugging
-
/* Enviorment Settings */
// Do not change unless you renamed the directories
define("PHP_DIRECTORY", '../test/'); // yotsubanome "C:\windows\system\"
/* Include */
-include_once(PHP_DIRECTORY.'env.php'); // Enviorment Settings
+include_once(PHP_DIRECTORY.'lib/lib_env.php'); // Enviorment Settings
include_once(PHP_DIRECTORY.'config.php'); // 引入設定檔
include_once(PHP_DIRECTORY.'lib/lib_language.php'); // 引入語系
include_once(PHP_DIRECTORY.'lib/lib_common.php'); // 引入共通函式檔案
$PTE = new PTELibrary(TEMPLATE_FILE); // PTE Library
if(version_compare(PHP_VERSION, '5.0.0', '>=')){ // PHP5+
- set_error_handler('PMCCore_errorHandler', E_ERROR | E_WARNING | E_USER_ERROR); // Handle Errors
+ set_error_handler('PMCCore_errorHandler', E_ERROR | E_WARNING | E_USER_ERROR); // Handle Errors
}else{
- set_error_handler('PMCCore_errorHandler');
+ //---- set_error_handler('PMCCore_errorHandler');
+ error_reporting(E_ALL); // show all errors for debugging
}
/* Lockdown [prevents posting] */
/* 更新記錄檔檔案/輸出討論串 */
/* ログの全体更新 */
function updatelog($resno=0,$page_num=-1,$single_page=false){
- global $PIO, $FileIO, $PTE, $PMS, $language, $LIMIT_SENSOR, $style_bar;
+ global $config, $PIO, $FileIO, $PTE, $PMS, $language, $LIMIT_SENSOR, $style_bar;
$adminMode = adminAuthenticate('check') && $page_num != -1 && !$single_page; // 前端管理模式
$adminFunc = ''; // 前端管理選擇
}else{ // 討論串分頁模式 (PHP動態輸出一頁份)
$threads_count = $PIO->threadCount(); // 討論串個數
//---- if($page_num < 0 || ($page_num * PAGE_DEF) >= $threads_count) error(_T('page_not_found')); // $page_num超過範圍
- if($threads_count = 1 && $page_num < 0 || ($page_num < 0 || ($page_num * PAGE_DEF) >= $threads_count)) error(_T('page_not_found')); // $page_num超過範圍
+ //++++---- Page 0 bug fix
+ if($page_num!=0) if($page_num < 0 || ($page_num * PAGE_DEF) >= $threads_count) error(_T('page_not_found')); // $page_num超過範圍
+ //++++----
$page_start = $page_end = $page_num; // 設定靜態頁面編號
$threads = $PIO->fetchThreadList($page_num * PAGE_DEF, PAGE_DEF); // 取出分頁後的討論串首篇列表
$PMS->useModuleMethods('ThreadOrder', array($resno,$page_num,$single_page,&$threads)); // "ThreadOrder" Hook Point
}
}
+ //++++---- Page 0 bug fix
+ if($tree_count==0 && $page_end==-1) $page_end = 0;
+ //++++----
// 預測過舊文章和將被刪除檔案
if(PIOSensor::check('predict', $LIMIT_SENSOR)){ // 是否需要預測
$old_sensor = true; // 標記打開
$pte_vals['{$PAGENAV}'] .= '<br style="clear: left;" />
</div>';
$dat .= $PTE->ParseBlock('MAIN', $pte_vals);
- foot($dat);
+ foot($dat); // the foot is a special core function wwww --sparky4
// 存檔 / 輸出
- //---- if($single_page || ($page_num == -1 && !$resno)){ // 靜態快取頁面生成
- if($threads_count = 1 && $page_num < 0 || ($single_page || ($page_num == -1 && !$resno))){ // 靜態快取頁面生成
+ if($single_page || ($page_num == -1 && !$resno)){ // 靜態快取頁面生成
if($page==0) $logfilename = PHP_SELF2;
else $logfilename = $page.PHP_EXT;
$fp = fopen($logfilename, 'w');
/* 輸出討論串架構 */
function arrangeThread($PTE, $tree, $tree_cut, $posts, $hiddenReply, $resno=0, $arr_kill, $arr_old, $kill_sensor, $old_sensor, $showquotelink=true, $adminMode=false, $hiddenImage, $hiddenImagP, $hiddenImagRP, $posts_img){
- global $PIO, $FileIO, $PMS, $language;
+ global $config, $PIO, $FileIO, $PMS, $language;
$thdat = ''; // 討論串輸出碼
$posts_count = count($posts); // 迴圈次數
// Tripcode indicator // t++ //++++----
// This may be a blob of code but it apparently works >< please help me here
$tripkeycount = substr_count($name, TRIP_KEY);
- if(ALLOW_NONAME==2){ // 強制砍名
+ if($config['ALLOW_NONAME']==3){
+ if($name) $name = '';
+ if($tripkeycount) $name = '';
+ if($email) $now = "<a href=\"mailto:$email\" class=\"linkmail\">$now</a>";
+ }elseif($config['ALLOW_NONAME']==2){ // 強制砍名
if($tripkeycount==1) $name = preg_match('/(\\'.TRIP_KEY.'.{10})/', $name, $matches) ? '<span class="postertrip">'.$matches[1].'</span>' : '';
if($tripkeycount==2) $name = preg_match('/(\\'.TRIP_KEY.TRIP_KEY.'.{16})/', $name, $matches) ? '<span class="postertrip">'.$matches[1].'</span>' : '';
if($tripkeycount==3) $name = preg_match('/(\\'.TRIP_KEY.'.{32})/', $name, $matches) ? '<span class="postertrip">'.$matches[1].'</span>' : '';
if(AUTO_LINK) $com = auto_link($com);
$com = quoteLight($com);
$com = quoteLight2($com);
- if(!$resno && MAX_LINES) list($com, $abbreviated) = abbreviate($com, MAX_LINES);
- if(isset($abbreviated) && $abbreviated && MAX_LINES) $com .= '<br /><span class="abbrev">'._T('long_comment').'<a href="'.PHP_SELF.'?res='.$tree[0].'#r'.$no.'">'._T('long_here').'</a>'._T('long_see').'</span>';
+ if(!$resno && $config['LINE_NUMBER']) list($com, $abbreviated) = abbreviate($com, $config['LINE_NUMBER']);
+ if(isset($abbreviated) && $abbreviated && $config['LINE_NUMBER']) $com .= '<br /><span class="abbrev">'._T('long_comment').'<a href="'.PHP_SELF.'?res='.$tree[0].'#r'.$no.'">'._T('long_here').'</a>'._T('long_see').'</span>';
if(USE_QUOTESYSTEM && $i){ // 啟用引用瀏覽系統
if(preg_match_all('/((?:>|>)+)(?:No\.)?(\d+)/i', $com, $matches, PREG_SET_ORDER)){ // 找尋>>No.xxx
/* 寫入記錄檔 */
/* 記事書き込み */
function regist(){
- global $PIO, $FileIO, $PMS, $language, $BAD_STRING, $BAD_FILEMD5, $BAD_IPADDR, $LIMIT_SENSOR;
+ global $config, $PIO, $FileIO, $PMS, $language, $BAD_STRING, $BAD_FILEMD5, $BAD_IPADDR, $LIMIT_SENSOR;
$dest = ''; $mes = ''; $up_incomplete = 0; $is_admin = false;
$path = realpath('.').DIRECTORY_SEPARATOR; // 此目錄的絕對位置
$size = @getimagesize($dest);
if(!is_array($size)) error(_T('regist_upload_notimage'), $dest); // $size不為陣列就不是圖檔
$imgsize = @filesize($dest); // 檔案大小
- if(!KB) $imgsize .= ' B'; // Bytes only
+ if(!$config['KB']) $imgsize .= ' B'; // Bytes only
else $imgsize = ($imgsize>=1024) ? (int)($imgsize/1024).' KB' : $imgsize.' B'; // KB和B的判別
switch($size[2]){ // 判斷上傳附加圖檔之格式
case 1 : $ext = ".gif"; break;
if($name){
// 名稱修整
$name = str_replace(TRIP_KEY, TRIP_KEY_FAKE, $name); // 防止トリップ偽造
- $name = str_replace(CAP_SUFFIX, CAP_SUFFIX_FAKE, $name); // 防止管理員キャップ偽造
+ $name = str_replace($config['CAP.SUFFIX'], $config['CAP.SUFFIX.FAKE'], $name); // 防止管理員キャップ偽造
$name = str_replace("\r\n", '', $name);
$nameOri = $name; // 名稱
// トリップ
//----"</b></font><font class=\"postertrip\">".
$name .= $metrip;
}
- if(CAP_ENABLE && preg_match('/(.*?)[##](.*)/u', $email, $aregs)){ // 管理員キャップ(Cap)機能
+ if($config['CAP.ENABLE'] && preg_match('/(.*?)[##](.*)/u', $email, $aregs)){ // 管理員キャップ(Cap)機能
$acap_name = $nameOri; $acap_pwd = strtr($aregs[2], array('&'=>'&'));
- if($acap_name==CAP_NAME && $acap_pwd==CAP_PASS){
- $name = '<span class="admin_cap">'.$name.CAP_SUFFIX.'</span>';
+ if($acap_name==$config['CAP.NAME'] && $acap_pwd==$config['CAP.PASSWORD']){
+ $name = '<span class="admin_cap">'.$name.$config['CAP.SUFFIX'].'</span>';
$is_admin = true;
$email = $aregs[1]; // 去除 #xx 密碼
}
$name = str_replace('&'.TRIP_KEY, '&'.TRIP_KEY, $name); // 避免 &#xxxx; 後面被視為 Trip 留下 & 造成解析錯誤
}
// End of Tripcode area--------------------------------------------------------------------------
+
// 內文修整
if((strlen($com) > COMM_MAX) && !$is_admin) error(_T('regist_commenttoolong'), $dest);
$com = CleanStr($com, $is_admin); // 引入$is_admin參數是因為當管理員キャップ啟動時,允許管理員依config設定是否使用HTML
$com = str_replace("\n", '', $com); // 若還有\n換行字元則取消換行
// 預設的內容
if(!$name || ereg("^[ | |]*$", $name)){
- if(ALLOW_NONAME) $name = DEFAULT_NONAME;
+ if($config['ALLOW_NONAME']) $name = $config['DEFAULT_NONAME'];
else error(_T('regist_withoutname'), $dest);
}
if(!$sub || ereg("^[ | |]*$", $sub)){
- if(ALLOW_NOSUB) $sub = DEFAULT_NOTITLE;
+ if($config['ALLOW_NOSUB']) $sub = $config['DEFAULT_NOTITLE'];
else error(_T('regist_withoutsubject'), $dest);
}
if(!$com || ereg("^[ | |\t]*$", $com)){
- if(ALLOW_NOSUB) $com = DEFAULT_NOCOMMENT;
+ if($config['ALLOW_NOCOM']) $com = $config['DEFAULT_NOCOMMENT'];
else error(_T('regist_withoutcomment'), $dest);
}
// 修整標籤樣式
if($up_incomplete) $com .= '<br /><br /><span class="warn_txt">'._T('notice_incompletefile').'</span>'; // 上傳附加圖檔不完全的提示
// 密碼和時間的樣式
- if($pwd=='') if(ALLOW_NOPASS) error(_T('regist_withoutpassword'), $dest); else $pwd = ($pwdc=='') ? substr(rand(),0,8) : $pwdc;
+ if($pwd=='') if($config['ALLOW_NOPASS']) error(_T('regist_withoutpassword'), $dest); else $pwd = ($pwdc=='') ? substr(rand(),0,8) : $pwdc;
$pass = $pwd ? substr(md5($pwd), 2, 8) : '*'; // 生成真正儲存判斷用的密碼
$youbi = array(_T('sun'),_T('mon'),_T('tue'),_T('wed'),_T('thu'),_T('fri'),_T('sat'));
//---- $yd = $youbi[gmdate('w', $time+TIME_ZONE*60*60)];
$yd = $youbi[date('w', $tome)];
//---- $now = gmdate('y/m/d', $time+TIME_ZONE*60*60).'('.(string)$yd.')'.gmdate('H:i', $time+TIME_ZONE*60*60);
- if(!EN_SEC)
- $now = date(DATE_FORMAT, $tome).'('.(string)$yd.')'.date('H:i', $tome);
- else $now = date(DATE_FORMAT, $tome).'('.(string)$yd.')'.date('H:i:s', $tome);
+ $now = date($config['DATE_FORMAT'], $tome).'('.(string)$yd.')'.date($config['TIME_FORMAT'], $tome);
//---- if(DISP_ID){ // 顯示ID
//---- if($email && DISP_ID==1) $now .= ' ID:????';
//---- }
if(DISP_ID){ // 顯示ID
if($email&&DISP_ID==1) $now .= " ID:????";
- else $now .= " ID:".substr(crypt(md5(getREMOTE_ADDR().IDSEED.date(DATE_FORMAT, $tome)),'id'), -8);
+ else $now .= " ID:".substr(crypt(md5(getREMOTE_ADDR().IDSEED.date($config['DATE_FORMAT'], $tome)),'id'), -8);
}
// 連續投稿 / 相同附加圖檔檢查
// 正式寫入儲存
$PIO->addPost($no,$resto,$md5chksum,$category,$tim,$ext,$imgW,$imgH,$imgsize,$filename,$W,$H,$pass,$now,$name,$email,$sub,$com,$host,$age,$status);
- //----$PIO->addPost($no,$now,$name,$email,$sub,$com,$age,$status,$host,$pwd,$ext,$W,$H,$tim,$md5chksum,$imgsize,$filename,$imgW,$imgH,$category,$resto);
+//---- $PIO->addPost($no,$now,$name,$email,$sub,$com,$age,$status,$host,$pwd,$ext,$W,$H,$tim,$md5chksum,$imgsize,$filename,$imgW,$imgH,$category,$resto);
$PIO->dbCommit();
$lastno = $PIO->getLastPostNo('afterCommit'); // 取得此新文章編號
$PMS->useModuleMethods('RegistAfterCommit', array($lastno, $resto, $name, $email, $sub, $com)); // "RegistAfterCommit" Hook Point
</div>
<form action="'.PHP_SELF.'" method="post" id="adminform">
<div id="admin-check" style="text-align: center;">
-'; //----class="bar_admin"
+';//----class="bar_admin"
echo $dat;
if(!$isCheck){
echo '<br />
</html>');
}
-////////////////
-// manage_css //
-////////////////
+/* manage_css */
+// http://www.magmagateau.com/fuukaba/ is the source of the code below
function manage_css(){
global $PMS, $language;
$order = array(); $line = '';
// Success messages
$action = (file_exists($style_dat)) ? _t('admin_updated') : _t('admin_created');
- $delete = (@unlink(CSS_DIR.CSVSS)) ? ' - <span class="warning">'.str_replace('[file]', CSS_DIR.CSVSS, _t('admin_deleted')).'</span>' : false;
+ //---- $delete = (@unlink(CSS_DIR.CSVSS)) ? ' - <span class="warning">'.str_replace('[file]', CSS_DIR.CSVSS, _t('admin_deleted')).'</span>' : false;
$fp = fopen($style_dat, 'w+');
set_file_buffer($fp, 0);
rewind($fp);
fputs($fp, $line);
fclose($fp);
@chmod($style_dat, 0666);
- echo '<div class="bar_managecss">'.str_replace('[file]', $style_dat, _t('admin_updated')).$delete.'</div>';
+ echo '<div class="bar_managecss">'.str_replace('[file]', $style_dat, _t('admin_updated'))./*----$delete.*/'</div>';
}
// Editing messages
if(file_exists(DATA_DIR.CSV_SS)){
$style_data = DATA_DIR.CSV_SS;
$style_mode = _t('admin_editing');
- }else{
- $style_data = CSS_DIR.CSVSS;
- $style_mode = _t('admin_imported');
+//---- }else{
+//---- $style_data = CSS_DIR.CSVSS;
+//---- $style_mode = _t('admin_imported');
}
echo '<div class="banner"><table width="100%"><tr><th class="bar_managecss">
'.str_replace('[file]', $style_data, $style_mode).'
}
// Read data from R3 DAT
- else if(file_exists(CSS_DIR.CSVSS)){
- $style_data = CSS_DIR.CSVSS;
- $lines = explode("\n", file_get_contents($style_data));
- $j = 0;
- foreach($lines as $null => $line){ // Line has data, or line is not commented out
- if(substr($line, 0, 2) != '//' && $line != ''){
- $bits = explode('[*]', $line);
- $j++;
- $style_name = $bits[0];
- $style_path = CSS_DIR.$bits[2];
- if(file_exists($style_path)){
- $style_short = $bits[1];
- if($bits[3]) $style_rel = ' checked="checked"';
- else $style_rel = false;
- $class = ($j % 2) ? 'row1' : 'row2'; // BG colour
- echo '<tr class="'.$class.'"><td align="left" colspan="2"><label><input name="default" type="radio"'.$style_rel.' value="'.$style_name.'" /> '.$style_path.'</label><input type="hidden" name="path['.$style_name.']" value="'.$bits[2].'" /></td><td align="left"><input name="names['.$style_name.']" value="'.$style_name.'" size="25" /></td><td align="left"><input name="short['.$style_name.']" value="'.$style_short.'" size="5" /></td><td align="left"><input name="order['.$style_name.']" size="2" value="'.$j.'" /></td></tr>';
- }
- }
- }
- }
+//---- else if(file_exists(CSS_DIR.CSVSS)){
+//---- $style_data = CSS_DIR.CSVSS;
+//---- $lines = explode("\n", file_get_contents($style_data));
+//---- $j = 0;
+//---- foreach($lines as $null => $line){ // Line has data, or line is not commented out
+//---- if(substr($line, 0, 2) != '//' && $line != ''){
+//---- $bits = explode('[*]', $line);
+//---- $j++;
+//---- $style_name = $bits[0];
+//---- $style_path = CSS_DIR.$bits[2];
+//---- if(file_exists($style_path)){
+//---- $style_short = $bits[1];
+//---- if($bits[3]) $style_rel = ' checked="checked"';
+//---- else $style_rel = false;
+//---- $class = ($j % 2) ? 'row1' : 'row2'; // BG colour
+//---- echo '<tr class="'.$class.'"><td align="left" colspan="2"><label><input name="default" type="radio"'.$style_rel.' value="'.$style_name.'" /> '.$style_path.'</label><input type="hidden" name="path['.$style_name.']" value="'.$bits[2].'" /></td><td align="left"><input name="names['.$style_name.']" value="'.$style_name.'" size="25" /></td><td align="left"><input name="short['.$style_name.']" value="'.$style_short.'" size="5" /></td><td align="left"><input name="order['.$style_name.']" size="2" value="'.$j.'" /></td></tr>';
+//---- }
+//---- }
+//---- }
+//---- }
$j++; $class = ($j % 2) ? 'row1' : 'row2';
/* 計算目前附加圖檔使用容量 (單位:KB) */
function total_size($isupdate=false){
- global $PIO, $FileIO;
+ global $config, $PIO, $FileIO;
$size = 0; $all = 0;
$cache_file = "./".SIZE_CACHE; // 附加圖檔使用容量值快取檔案
$all = $sp[0];
unset($sp);
}
- return (int)($all / 1024);
+//---- return (int)($all / 1024);
+ if(!$config['KB']) return (int)($all);
+ else return (int)($all / 1024);
}
/* 搜尋(全文檢索)功能 */
$dat .= "<div>$links</div>\n";
for($i = 0; $i < $loglist_cut_count; $i++){
$posts = $PIO->fetchPosts($loglist_cut[$i]); // 取得文章內容
- $dat .= arrangeThread($PTE, ($posts[0]['resto'] ? $posts[0]['resto'] : $posts[0]['no']), null, $posts, 0, $loglist_cut[$i], array(), array(), false, false, false); // 逐個輸出 (引用連結不顯示)
+ $dat .= arrangeThread($PTE, ($posts[0]['resto'] ? $posts[0]['resto'] : $posts[0]['no']), null, $posts, 0, $loglist_cut[$i], array(), array(), false, false, false, 0, 0, 0, 0, 0); // 逐個輸出 (引用連結不顯示)
}
$dat .= '<table border="1"><tr>';
/* 顯示系統各項資訊 */
function showstatus(){
- global $PTE, $PIO, $FileIO, $PMS, $language, $LIMIT_SENSOR;
+ global $config, $PTE, $PIO, $FileIO, $PMS, $language, $LIMIT_SENSOR;
$countline = $PIO->postCount(); // 計算投稿文字記錄檔目前資料筆數
$counttree = $PIO->threadCount(); // 計算樹狀結構記錄檔目前資料筆數
$tmp_total_size = total_size(); // 附加圖檔使用量總大小
$tmp_ts_ratio = STORAGE_MAX > 0 ? $tmp_total_size / STORAGE_MAX : 0; // 附加圖檔使用量
+ if(!$config['KB']) $kbb = ' B';
+ else $kbb = ' KB';
// 決定「附加圖檔使用量」提示文字顏色
if($tmp_ts_ratio < 0.3 ) $clrflag_sl = '235CFF';
<tr><td>'._T('info_basic_bumphours').'</td><td colspan="3"> '.MAX_AGE_TIME.' '._T('info_basic_hours').' '._T('info_basic_0disable').'</td></tr>
<tr><td>'._T('info_basic_urllinking').'</td><td colspan="3"> '.AUTO_LINK.' '._T('info_0no1yes').'</td></tr>
<tr><td>'._T('info_basic_com_limit').'</td><td colspan="3"> '.COMM_MAX._T('info_basic_com_after').'</td></tr>
-<tr><td>'._T('info_basic_anonpost').'</td><td colspan="3"> '.ALLOW_NONAME.' '._T('info_basic_anonpost_opt').'</td></tr>
+<tr><td>'._T('info_basic_anonpost').'</td><td colspan="3"> '.$config['ALLOW_NONAME'].' '._T('info_basic_anonpost_opt').'</td></tr>
<tr><td>'._T('info_basic_del_incomplete').'</td><td colspan="3"> '.KILL_INCOMPLETE_UPLOAD.' '._T('info_0no1yes').'</td></tr>
<tr><td>'._T('info_basic_use_sample',THUMB_Q).'</td><td colspan="3"> '.USE_THUMB.' '._T('info_0notuse1use').'</td></tr>
<tr><td>'._T('info_basic_useblock').'</td><td colspan="3"> '.BAN_CHECK.' '._T('info_0disable1enable').'</td></tr>
<tr><td>'._T('info_basic_showid').'</td><td colspan="3"> '.DISP_ID.' '._T('info_basic_showid_after').'</td></tr>
<tr><td>'._T('info_basic_cr_limit').'</td><td colspan="3"> '.BR_CHECK._T('info_basic_cr_after').'</td></tr>
<!--<tr><td>'._T('info_basic_timezone').'</td><td colspan="3"> GMT </td></tr>-->
-<tr><td>'._T('info_basic_max_lines_limit').'</td><td colspan="3"> '.MAX_LINES._T('info_basic_max_lines_after').'</td></tr>
+<tr><td>'._T('info_basic_line_number_limit').'</td><td colspan="3"> '.$config['LINE_NUMBER']._T('info_basic_line_number_after').'</td></tr>
<tr><td>'._T('info_basic_theme').'</td><td colspan="3"> '.$PTE->BlockValue('THEMENAME').' '.$PTE->BlockValue('THEMEVER').'<br/>by '.$PTE->BlockValue('THEMEAUTHOR').'</td></tr>
<tr><td align="center" colspan="4">'._T('info_dsusage_top').'</td></tr>
<tr align="center"><td>'._T('info_basic_threadcount').'</td><td colspan="'.(isset($piosensorInfo)?'2':'3').'"> '.$counttree.' '._T('info_basic_threads').'</td>'.(isset($piosensorInfo)?'<td rowspan="2">'.$piosensorInfo.'</td>':'').'</tr>
if(STORAGE_LIMIT){
$dat .= '
-<tr align="center"><td>'._T('info_fileusage_limit').'</td><td colspan="2">'.STORAGE_MAX.' KB</td><td rowspan="2">'._T('info_dsusage_usage').'<br /><span style="color: #'.$clrflag_sl.'">'.substr(($tmp_ts_ratio * 100), 0, 6).'</span> %</td></tr>
-<tr align="center"><td>'._T('info_fileusage_count').'</td><td colspan="2"><span style="color: #'.$clrflag_sl.'">'.$tmp_total_size.' KB</span></td></tr>';
+<tr align="center"><td>'._T('info_fileusage_limit').'</td><td colspan="2">'.STORAGE_MAX.$kbb.'</td><td rowspan="2">'._T('info_dsusage_usage').'<br /><span style="color: #'.$clrflag_sl.'">'.substr(($tmp_ts_ratio * 100), 0, 6).'</span> %</td></tr>
+<tr align="center"><td>'._T('info_fileusage_count').'</td><td colspan="2"><span style="color: #'.$clrflag_sl.'">'.$tmp_total_size.$kbb.'</span></td></tr>';
}else{
$dat .= '
-<tr align="center"><td>'._T('info_fileusage_count').'</td><td>'.$tmp_total_size.' KB</td><td colspan="2">'._T('info_dsusage_usage').'<br /><span style="color: green;">'._T('info_fileusage_unlimited').'</span></td></tr>';
+<tr align="center"><td>'._T('info_fileusage_count').'</td><td>'.$tmp_total_size.$kbb.'</td><td colspan="2">'._T('info_dsusage_usage').'<br /><span style="color: green;">'._T('info_fileusage_unlimited').'</span></td></tr>';
}
$dat .= '