diff --git a/adm/board_copy_update.php b/adm/board_copy_update.php index e053ad551..1606556c4 100644 --- a/adm/board_copy_update.php +++ b/adm/board_copy_update.php @@ -181,6 +181,9 @@ if (count($file_copy)) { } } +delete_cache_latest($bo_table); +delete_cache_latest($target_table); + echo ""; alert("복사에 성공 했습니다.", './board_copy.php?bo_table='.$bo_table.'&'.$qstr); diff --git a/adm/board_delete.inc.php b/adm/board_delete.inc.php index 123fe00f3..7887859a1 100644 --- a/adm/board_delete.inc.php +++ b/adm/board_delete.inc.php @@ -26,6 +26,8 @@ sql_query(" delete from {$g4['board_file_table']} where bo_table = '{$tmp_bo_tab // 게시판 테이블 DROP sql_query(" drop table {$g4['write_prefix']}{$tmp_bo_table} ", FALSE); +delete_cache_latest($tmp_bo_table); + // 게시판 폴더 전체 삭제 rm_rf(G4_DATA_PATH.'/file/'.$tmp_bo_table); ?> \ No newline at end of file diff --git a/adm/board_form_update.php b/adm/board_form_update.php index 83e9c58af..6e76c85cf 100644 --- a/adm/board_form_update.php +++ b/adm/board_form_update.php @@ -278,5 +278,7 @@ if ($fields) { sql_query($sql); } +delete_cache_latest($bo_table); + goto_url("./board_form.php?w=u&bo_table={$bo_table}&{$qstr}"); ?> diff --git a/bbs/delete.php b/bbs/delete.php index f5fb6c675..9d38fda5e 100644 --- a/bbs/delete.php +++ b/bbs/delete.php @@ -121,5 +121,7 @@ if ($count_write > 0 || $count_comment > 0) @include_once($board_skin_path.'/delete.tail.skin.php'); +delete_cache_latest($bo_table); + goto_url('./board.php?bo_table='.$bo_table.'&page='.$page.$qstr); ?> diff --git a/bbs/delete_comment.php b/bbs/delete_comment.php index 367e1f64e..d8cf767d2 100644 --- a/bbs/delete_comment.php +++ b/bbs/delete_comment.php @@ -80,8 +80,9 @@ sql_query(" delete from {$g4[board_new_table]} where bo_table = '{$bo_table}' an // 사용자 코드 실행 @include_once($board_skin_path.'/delete_comment.skin.php'); -// 4.1 @include_once($board_skin_path.'/delete_comment.tail.skin.php'); +delete_cache_latest($bo_table); + goto_url('./board.php?bo_table='.$bo_table.'&wr_id='.$write[wr_parent].'&page='.$page. $qstr); ?> diff --git a/bbs/move_update.php b/bbs/move_update.php index b0c4cbfb0..50cc7d142 100644 --- a/bbs/move_update.php +++ b/bbs/move_update.php @@ -19,8 +19,6 @@ $save_count_write = 0; $save_count_comment = 0; $cnt = 0; -// SQL Injection 으로 인한 코드 보완 -//$sql = " select distinct wr_num from {$write_table} where wr_id in (" . stripslashes($wr_id_list) . ") order by wr_id "; $sql = " select distinct wr_num from $write_table where wr_id in ({$wr_id_list}) order by wr_id "; $result = sql_query($sql); while ($row = sql_fetch_array($result)) @@ -39,14 +37,13 @@ while ($row = sql_fetch_array($result)) $next_wr_num = get_next_num($move_write_table); - //$sql2 = " select * from {$write_table} where wr_num = '{$wr_num}' order by wr_parent, wr_comment desc, wr_id "; $sql2 = " select * from $write_table where wr_num = '$wr_num' order by wr_parent, wr_is_comment, wr_comment desc, wr_id "; $result2 = sql_query($sql2); while ($row2 = sql_fetch_array($result2)) { $nick = cut_str($member['mb_nick'], $config['cf_cut_name']); if (!$row2['wr_is_comment'] && $config['cf_use_copy_log']) - $row2['wr_content'] .= "\n".'[이 게시물은 '.$nick.'님에 의해 '.G4_TIME_YMDHIS.' '.$board['bo_subject'].'에서 '.($sw == 'copy' ? '복사' : '이동').' 됨]'; + $row2['wr_content'] .= PHP_EOL.'[이 게시물은 '.$nick.'님에 의해 '.G4_TIME_YMDHIS.' '.$board['bo_subject'].'에서 '.($sw == 'copy' ? '복사' : '이동').' 됨]'; $sql = " insert into $move_write_table set wr_num = '$next_wr_num', @@ -152,15 +149,18 @@ while ($row = sql_fetch_array($result)) $cnt++; } - sql_query(" update {$g4['board_table']} set bo_count_write = bo_count_write + '$count_write' where bo_table = '$move_bo_table' "); sql_query(" update {$g4['board_table']} set bo_count_comment = bo_count_comment + '$count_comment' where bo_table = '$move_bo_table' "); + + delete_cache_latest($move_bo_table); } $save_count_write += $count_write; $save_count_comment += $count_comment; } +delete_cache_latest($bo_table); + if ($sw == "move") { for ($i=0; $i= $board['bo_comment_level'])) $sql = " insert into {$g4['scrap_table']} ( mb_id, bo_table, wr_id, ms_datetime ) values ( '{$member['mb_id']}', '$bo_table', '$wr_id', '".G4_TIME_YMDHIS."' ) "; sql_query($sql); +delete_cache_latest($bo_table); + echo << if (confirm('이 글을 스크랩 하였습니다.\\n\\n지금 스크랩을 확인하시겠습니까?')) diff --git a/bbs/write.php b/bbs/write.php index f00d187f9..198d1cc29 100644 --- a/bbs/write.php +++ b/bbs/write.php @@ -156,6 +156,8 @@ if ($w == '') { $reply = $reply_array['wr_reply'] . $reply_char; $title_msg = '글답변'; + + $write['wr_subject'] = 'Re: '.$write['wr_subject']; } // 그룹접근 가능 diff --git a/lib/common.lib.php b/lib/common.lib.php index 3b70f9303..be5cb2a69 100644 --- a/lib/common.lib.php +++ b/lib/common.lib.php @@ -380,16 +380,11 @@ function get_list($write_row, $board, $skin_url, $subject_len=40) $reply = $list['wr_reply']; - $list['reply'] = ''; - if (strlen($reply) > 0) - { - for ($k=0; $k'; + $list['icon_reply'] = '답변글'; $list['icon_link'] = ''; if ($list['wr_link1'] || $list['wr_link2']) diff --git a/lib/thumbnail.lib.php b/lib/thumbnail.lib.php index 250615dc8..ebd9b4d79 100644 --- a/lib/thumbnail.lib.php +++ b/lib/thumbnail.lib.php @@ -98,7 +98,7 @@ function thumbnail($filename, $source_path, $target_path, $thumb_width, $thumb_h @chmod($target_path, 0707); } - $thumb_file = "$target_path/{$thumb_filename}_{$thumb_width}x{$thumb_height}.png"; + $thumb_file = "$target_path/thumb-{$thumb_filename}_{$thumb_width}x{$thumb_height}.png"; $thumb_time = @filemtime($thumb_file); $source_file = "$source_path/$filename"; $source_time = @filemtime($source_file); @@ -112,7 +112,7 @@ function thumbnail($filename, $source_path, $target_path, $thumb_width, $thumb_h // 이미지 파일이 없거나 아님 if (!$size[0]) { if (!$thumb_height) $thumb_height = $thumb_width; - $thumb_file = "$target_path/noimg_{$thumb_width}x{$thumb_height}.png"; + $thumb_file = "$target_path/thumb-noimg_{$thumb_width}x{$thumb_height}.png"; if (!file_exists($thumb_file)) { $target = imagecreate($thumb_width, $thumb_height); imagecolorallocate($target, 250, 250, 250); diff --git a/skin/board/basic/list.skin.php b/skin/board/basic/list.skin.php index 89d933507..46ae497e5 100644 --- a/skin/board/basic/list.skin.php +++ b/skin/board/basic/list.skin.php @@ -78,7 +78,6 @@ if ($is_nogood) $colspan++; diff --git a/skin/board/basic/write.skin.php b/skin/board/basic/write.skin.php index f870310b8..736895f42 100644 --- a/skin/board/basic/write.skin.php +++ b/skin/board/basic/write.skin.php @@ -191,8 +191,8 @@ function html_auto_br(obj) function fwrite_submit(f) { - - + + var subject = ""; var content = "";