Skip to content
This repository has been archived by the owner on Jun 24, 2021. It is now read-only.

Commit

Permalink
잘못된 표기 또는 문법 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
thisgun committed May 8, 2020
1 parent b8424a1 commit 6e51d92
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 18 deletions.
2 changes: 1 addition & 1 deletion bbs/db_table.optimize.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
}

// 음성 캡챠 파일 삭제
$captcha_mp3 = glob(G5_PATH.'/data/cache/kcaptcha-*.mp3');
$captcha_mp3 = glob(G5_DATA_PATH.'/cache/kcaptcha-*.mp3');
if($captcha_mp3 && is_array($captcha_mp3)) {
foreach ($captcha_mp3 as $file) {
if (filemtime($file) + 86400 < G5_SERVER_TIME) {
Expand Down
6 changes: 3 additions & 3 deletions bbs/download.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,17 +108,17 @@

if(preg_match("/msie/i", $_SERVER['HTTP_USER_AGENT']) && preg_match("/5\.5/", $_SERVER['HTTP_USER_AGENT'])) {
header("content-type: doesn/matter");
header("content-length: ".filesize("$filepath"));
header("content-length: ".filesize($filepath));
header("content-disposition: attachment; filename=\"$original\"");
header("content-transfer-encoding: binary");
} else if (preg_match("/Firefox/i", $_SERVER['HTTP_USER_AGENT'])){
header("content-type: file/unknown");
header("content-length: ".filesize("$filepath"));
header("content-length: ".filesize($filepath));
header("content-disposition: attachment; filename=\"".basename($file['bf_source'])."\"");
header("content-description: php generated data");
} else {
header("content-type: file/unknown");
header("content-length: ".filesize("$filepath"));
header("content-length: ".filesize($filepath));
header("content-disposition: attachment; filename=\"$original\"");
header("content-description: php generated data");
}
Expand Down
11 changes: 8 additions & 3 deletions bbs/qadownload.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,26 @@

$filepath = G5_DATA_PATH.'/qa/'.$file['qa_file'.$no];
$filepath = addslashes($filepath);
if (!is_file($filepath) || !file_exists($filepath))
$file_exist_check = (!is_file($filepath) || !file_exists($filepath)) ? false : true;

if ( false === run_replace('qa_download_file_exist_check', $file_exist_check, $file) ){
alert('파일이 존재하지 않습니다.');
}

$g5['title'] = '다운로드 &gt; '.conv_subject($file['qa_subject'], 255);

run_event('qa_download_file_header', $file, $file_exist_check);

$original = urlencode($file['qa_source'.$no]);

if(preg_match("/msie/i", $_SERVER['HTTP_USER_AGENT']) && preg_match("/5\.5/", $_SERVER['HTTP_USER_AGENT'])) {
header("content-type: doesn/matter");
header("content-length: ".filesize("$filepath"));
header("content-length: ".filesize($filepath));
header("content-disposition: attachment; filename=\"$original\"");
header("content-transfer-encoding: binary");
} else {
header("content-type: file/unknown");
header("content-length: ".filesize("$filepath"));
header("content-length: ".filesize($filepath));
header("content-disposition: attachment; filename=\"$original\"");
header("content-description: php generated data");
}
Expand Down
22 changes: 11 additions & 11 deletions bbs/write_update.php
Original file line number Diff line number Diff line change
Expand Up @@ -466,9 +466,9 @@
$upload[$i]['source'] = '';
$upload[$i]['filesize'] = 0;
$upload[$i]['image'] = array();
$upload[$i]['image'][0] = '';
$upload[$i]['image'][1] = '';
$upload[$i]['image'][2] = '';
$upload[$i]['image'][0] = 0;
$upload[$i]['image'][1] = 0;
$upload[$i]['image'][2] = 0;
$upload[$i]['fileurl'] = '';
$upload[$i]['thumburl'] = '';
$upload[$i]['storage'] = '';
Expand Down Expand Up @@ -593,10 +593,10 @@
bf_fileurl = '{$upload[$i]['fileurl']}',
bf_thumburl = '{$upload[$i]['thumburl']}',
bf_storage = '{$upload[$i]['storage']}',
bf_filesize = '{$upload[$i]['filesize']}',
bf_width = '{$upload[$i]['image']['0']}',
bf_height = '{$upload[$i]['image']['1']}',
bf_type = '{$upload[$i]['image']['2']}',
bf_filesize = '".(int)$upload[$i]['filesize']."',
bf_width = '".(int)$upload[$i]['image'][0]."',
bf_height = '".(int)$upload[$i]['image'][1]."',
bf_type = '".(int)$upload[$i]['image'][2]."',
bf_datetime = '".G5_TIME_YMDHIS."'
where bo_table = '{$bo_table}'
and wr_id = '{$wr_id}'
Expand Down Expand Up @@ -626,10 +626,10 @@
bf_thumburl = '{$upload[$i]['thumburl']}',
bf_storage = '{$upload[$i]['storage']}',
bf_download = 0,
bf_filesize = '{$upload[$i]['filesize']}',
bf_width = '{$upload[$i]['image']['0']}',
bf_height = '{$upload[$i]['image']['1']}',
bf_type = '{$upload[$i]['image']['2']}',
bf_filesize = '".(int)$upload[$i]['filesize']."',
bf_width = '".(int)$upload[$i]['image'][0]."',
bf_height = '".(int)$upload[$i]['image'][1]."',
bf_type = '".(int)$upload[$i]['image'][2]."',
bf_datetime = '".G5_TIME_YMDHIS."' ";
sql_query($sql);

Expand Down

0 comments on commit 6e51d92

Please sign in to comment.