채택완료

특정 게시판으로 게시물 이동시키는 버튼 만들기

Copy
<div id="copymove" class="new_win">

    <h1 id="win_title"><?php echo $g5['title'] ?></h1>

    <form name="fboardmoveall" method="post" action="./move_update.php" onsubmit="return fboardmoveall_submit(this);">

    <input type="hidden" name="sw" value="<?php echo $sw ?>">

    <input type="hidden" name="bo_table" value="<?php echo $bo_table ?>">

    <input type="hidden" name="wr_id_list" value="<?php echo $wr_id_list ?>">

    <input type="hidden" name="sfl" value="<?php echo $sfl ?>">

    <input type="hidden" name="stx" value="<?php echo $stx ?>">

    <input type="hidden" name="spt" value="<?php echo $spt ?>">

    <input type="hidden" name="sst" value="<?php echo $sst ?>">

    <input type="hidden" name="sod" value="<?php echo $sod ?>">

    <input type="hidden" name="page" value="<?php echo $page ?>">

    <input type="hidden" name="act" value="<?php echo $act ?>">

    <input type="hidden" name="url" value="<?php echo get_text(clean_xss_tags($_SERVER['HTTP_REFERER'])); ?>">

 

    <div class="tbl_head01 tbl_wrap">

        <table>

        <caption><?php echo $act ?>할 게시판을 한개 이상 선택하여 주십시오.</caption>

        <thead>

        <tr>

            <th scope="col">

                <label for="chkall" class="sound_only">현재 페이지 게시판 전체</label>

                <input type="checkbox" id="chkall" onclick="if (this.checked) all_checked(true); else all_checked(false);">

            </th>

            <th scope="col">게시판</th>

        </tr>

        </thead>

        <tbody>

        <?php for ($i=0; $i<count($list); $i++) {

            $atc_mark = '';

            $atc_bg = '';

            if ($list[$i]['bo_table'] == $bo_table) { // 게시물이 현재 속해 있는 게시판이라면

                $atc_mark = '<span class="copymove_current">현재<span class="sound_only">게시판</span></span>';

                $atc_bg = 'copymove_currentbg';

            }

        ?>

        <tr class="<?php echo $atc_bg; ?>">

            <td class="td_chk">

                <label for="chk<?php echo $i ?>" class="sound_only"><?php echo $list[$i]['bo_table'] ?></label>

                <input type="checkbox" value="<?php echo $list[$i]['bo_table'] ?>" id="chk<?php echo $i ?>" name="chk_bo_table[]">

            </td>

            <td>

                <label for="chk<?php echo $i ?>">

                    <?php

                    echo $list[$i]['gr_subject'] . ' &gt; ';

                    $save_gr_subject = $list[$i]['gr_subject'];

                    ?>

                    <?php echo $list[$i]['bo_subject'] ?> (<?php echo $list[$i]['bo_table'] ?>)

                    <?php echo $atc_mark; ?>

                </label>

            </td>

        </tr>

        <?php } ?>

        </tbody>

        </table>

    </div>

 

    <div class="win_btn">

        <input type="submit" value="<?php echo $act ?>" id="btn_submit" class="btn_submit">

    </div>

    </form>

 

</div>


여기까지는 찾았는데 일일이 hidden 값으로 submit 하는 방법 밖에 없는 건가요? ㅠ
 

고수님들의 도움 부탁드립니다. ㅠㅠ

|

답변 1개 / 댓글 1개

채택된 답변
+20 포인트

<?php for ($i=0; $i<count($list); $i++) {

<?php for ($i=0; $i<count($list); $i++) {
  if ($list[$i]['bo_table'] != '[특정 게시판 ID]')
    continue;

답변에 대한 댓글 1개

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