From f4dfbacf0316746518195f441a5c7a9e98c7a46a Mon Sep 17 00:00:00 2001 From: thisgun Date: Tue, 4 Jun 2024 10:25:59 +0900 Subject: [PATCH] =?UTF-8?q?=EA=B8=80=EB=B3=B5=EC=82=AC=20sql=20query?= =?UTF-8?q?=EC=97=90=20=EB=B3=8B=EC=B9=AD=20as=20=EC=B6=94=EA=B0=80=20?= =?UTF-8?q?=EB=B0=8F=20=ED=8F=AC=EC=9D=B8=ED=8A=B8=20=EC=97=85=EB=8D=B0?= =?UTF-8?q?=EC=9D=B4=ED=8A=B8=20=EC=BD=94=EB=93=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bbs/move_update.php | 2 +- bbs/poll_update.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bbs/move_update.php b/bbs/move_update.php index cbef072da..7c417f606 100644 --- a/bbs/move_update.php +++ b/bbs/move_update.php @@ -80,7 +80,7 @@ while ($row = sql_fetch_array($result)) } $sql = " insert into $move_write_table - set wr_num = " . ($next_wr_num ? "'$next_wr_num'" : "(SELECT IFNULL(MIN(wr_num) - 1, -1) FROM $move_write_table sq) ") . ", + set wr_num = " . ($next_wr_num ? "'$next_wr_num'" : "(SELECT IFNULL(MIN(wr_num) - 1, -1) FROM $move_write_table as sq) ") . ", wr_reply = '{$row2['wr_reply']}', wr_is_comment = '{$row2['wr_is_comment']}', wr_comment = '{$row2['wr_comment']}', diff --git a/bbs/poll_update.php b/bbs/poll_update.php index cca29431b..d6fb5d809 100644 --- a/bbs/poll_update.php +++ b/bbs/poll_update.php @@ -3,7 +3,7 @@ include_once('./_common.php'); $po_id = isset($_POST['po_id']) ? preg_replace('/[^0-9]/', '', $_POST['po_id']) : 0; -$po = sql_fetch(" select * from {$g5['poll_table']} where po_id = '{$_POST['po_id']}' "); +$po = sql_fetch(" select * from {$g5['poll_table']} where po_id = '$po_id' "); if (! (isset($po['po_id']) && $po['po_id'])) alert('po_id 값이 제대로 넘어오지 않았습니다.');