From 3beaf71e163c87b82d5e7ff3153610515b896d60 Mon Sep 17 00:00:00 2001 From: thisgun Date: Fri, 29 Sep 2017 12:19:50 +0900 Subject: [PATCH] =?UTF-8?q?=EB=8F=99=EC=9D=BC=ED=95=9C=20=EA=B2=8C?= =?UTF-8?q?=EC=8B=9C=ED=8C=90=EC=9C=BC=EB=A1=9C=20=EA=B8=80=20=EB=B3=B5?= =?UTF-8?q?=EC=82=AC=EC=8B=9C=20=ED=8C=8C=EC=9D=BC=20=EB=B3=B5=EC=82=AC=20?= =?UTF-8?q?=EC=B2=98=EB=A6=AC=20=EC=88=98=EC=A0=95=20(=20=EC=A0=9C?= =?UTF-8?q?=EC=9D=B4=ED=94=84=EB=A1=9C=20=EB=8B=98=20=EC=A0=9C=EC=95=88=20?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bbs/move_update.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bbs/move_update.php b/bbs/move_update.php index ac6c0582e..78abbd8cd 100644 --- a/bbs/move_update.php +++ b/bbs/move_update.php @@ -115,7 +115,9 @@ while ($row = sql_fetch_array($result)) if ($row3['bf_file']) { // 원본파일을 복사하고 퍼미션을 변경 - @copy($src_dir.'/'.$row3['bf_file'], $dst_dir.'/'.$row3['bf_file']); + // 제이프로님 코드제안 적용 + $copy_file_name = ($bo_table !== $move_bo_table) ? $row3['bf_file'] : $row2['wr_id'].'_copy_'.$insert_id.'_'.$row3['bf_file']; + @copy($src_dir.'/'.$row3['bf_file'], $dst_dir.'/'.$copy_file_name); @chmod($dst_dir/$row3['bf_file'], G5_FILE_PERMISSION); } @@ -124,7 +126,7 @@ while ($row = sql_fetch_array($result)) wr_id = '$insert_id', bf_no = '{$row3['bf_no']}', bf_source = '".addslashes($row3['bf_source'])."', - bf_file = '{$row3['bf_file']}', + bf_file = '$copy_file_name', bf_download = '{$row3['bf_download']}', bf_content = '".addslashes($row3['bf_content'])."', bf_filesize = '{$row3['bf_filesize']}',