채택완료

코멘트 작성일 변경입니다. 도와주세요..

2015-08-16 (일) 03:11:02 2,247

일단 wiew_comment.skin.php 에

<input type=hidden id='secret_comment_<?=$comment_id?>' value="<?=strstr($list[$i][wr_option],"secret")?>"> 아래에 이렇게 작성했습니다.

Copy
<?php if ($is_admin) { ?><form name='hp_comment_update' method='post' style='padding:0;' 
action="<?php echo $board_skin_path; 
?>/write_comment_update.skin.php">          <?php            $sql_comment = " select wr_id, wr_datetime from $write_table where wr_id = '$comment_id' ";            $result_comment = sql_query($sql_comment);            while($row_comment = mysql_fetch_array($result_comment)) {            ?>            <input type="hidden" name="cid" value="<?php echo $comment_id; ?>" />            작성일 <input required style="width:140px;" name="cdate" maxlength="19" value="<?php echo $row_comment[wr_datetime]; ?>" />            <input type="submit" name="submit"  value="수정">          </form>        <?php } ?>​

이렇게 작성했습니다.

write_comment_update.skin.php 는

어떻게 작성을 해야 할까요?

|

답변 1개

채택된 답변
+20 포인트

$que = "update $write_table set wr_datetime = '".$_POST['cdate']."' where wr_id = '$wr_id'";

sql_query( $que );

이렇게 하심 될 것 같은데요

답변을 작성하려면 로그인이 필요합니다.