From 67530cc3a59c2bb7ddbe36d98c2122cfdba4b8b6 Mon Sep 17 00:00:00 2001 From: chicpro Date: Thu, 15 May 2014 14:04:36 +0900 Subject: [PATCH] =?UTF-8?q?=EB=B9=84=ED=9A=8C=EC=9B=90=EC=9D=B4=20?= =?UTF-8?q?=EC=9E=90=EB=B0=94=EC=8A=A4=ED=81=AC=EB=A6=BD=ED=8A=B8=EB=A5=BC?= =?UTF-8?q?=20=EC=9D=B4=EC=9A=A9=ED=95=B4=20=EB=8C=93=EA=B8=80=20=EC=88=98?= =?UTF-8?q?=EC=A0=95=ED=95=A0=20=EC=88=98=20=EC=9E=88=EB=8A=94=20=EC=98=A4?= =?UTF-8?q?=EB=A5=98=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bbs/write_comment_update.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bbs/write_comment_update.php b/bbs/write_comment_update.php index df8a7e613..6d664d7b4 100644 --- a/bbs/write_comment_update.php +++ b/bbs/write_comment_update.php @@ -241,7 +241,7 @@ if ($w == 'c') // 댓글 입력 } else if ($w == 'cu') // 댓글 수정 { - $sql = " select mb_id, wr_comment, wr_comment_reply from $write_table + $sql = " select mb_id, wr_password, wr_comment, wr_comment_reply from $write_table where wr_id = '$comment_id' "; $comment = $reply_array = sql_fetch($sql); $tmp_comment = $reply_array['wr_comment']; @@ -274,6 +274,9 @@ else if ($w == 'cu') // 댓글 수정 } else if ($member['mb_id']) { if ($member['mb_id'] != $comment['mb_id']) alert('자신의 글이 아니므로 수정할 수 없습니다.'); + } else { + if($comment['wr_password'] != $wr_password) + alert('댓글을 수정할 권한이 없습니다.'); } $sql = " select count(*) as cnt from $write_table