안녕하세요~~또 질문올립니다 꼭좀봐주세요

안녕하세요~~또 질문올립니다 꼭좀봐주세요

QA

안녕하세요~~또 질문올립니다 꼭좀봐주세요

본문

메인에 있는 최신 추천등등 의 리스트들을 각각의 카테고리에 나오도록 설정했습니다

그런데..관리자 페이지에서 최신추천등등상품리스트를 안보이게 체크헤재하면...당연히 각 카테고리에서도 안나옵니다 그런데...제가 하고십은것은..

메인과 별게로 ...따로 관리자 페이지에 체크및설정란을 만들어서 관리하고십은데요

관리자페이지에 나오는것까진 성공...했습니다..그런데...이걸...체크하고 확인을누르면...저장이

되질안습니다...그래서 configformupdate.php 과 configform.php 과 shop/listtype.php 과shop/list.php 파일들을 손봤거든요...

그런데요 

1054 : Unknown column 'de_type6_list_use' in 'field list'

 error file : /adm/shop_admin/configformupdate.php

이런 문구만 뜨는군요...

아~ 어떻게 방법이 없을까요..ㅠㅠ

수정한내용은요...

[code] 

/adm/shop_admin/configformupdate.php80번재줄부터이구요

                de_type6_list_use             = '{$_POST['de_type6_list_use']}',

                de_type6_list_skin            = '{$_POST['de_type6_list_skin']}',

                de_type6_list_mod             = '{$_POST['de_type6_list_mod']}',

                de_type6_list_row             = '{$_POST['de_type6_list_row']}',

                de_type6_img_width            = '{$_POST['de_type6_img_width']}',

                de_type6_img_height           = '{$_POST['de_type6_img_height']}',

                de_type7_list_use             = '{$_POST['de_type7_list_use']}',

                de_type7_list_skin            = '{$_POST['de_type7_list_skin']}',

                de_type7_list_mod             = '{$_POST['de_type7_list_mod']}',

                de_type7_list_row             = '{$_POST['de_type7_list_row']}',

                de_type7_img_width            = '{$_POST['de_type7_img_width']}',

                de_type7_img_height           = '{$_POST['de_type7_img_height']}',

                de_type8_list_use             = '{$_POST['de_type8_list_use']}',

                de_type8_list_skin            = '{$_POST['de_type8_list_skin']}',

                de_type8_list_mod             = '{$_POST['de_type8_list_mod']}',

                de_type8_list_row             = '{$_POST['de_type8_list_row']}',

                de_type8_img_width            = '{$_POST['de_type8_img_width']}',

                de_type8_img_height           = '{$_POST['de_type8_img_height']}',

                de_type9_list_use             = '{$_POST['de_type9_list_use']}',

                de_type9_list_skin            = '{$_POST['de_type9_list_skin']}',

                de_type9_list_mod             = '{$_POST['de_type9_list_mod']}',

                de_type9_list_row             = '{$_POST['de_type9_list_row']}',

                de_type9_img_width            = '{$_POST['de_type9_img_width']}',

                de_type9_img_height           = '{$_POST['de_type9_img_height']}',

                de_type10_list_use             = '{$_POST['de_type10_list_use']}',

                de_type10_list_skin            = '{$_POST['de_type10_list_skin']}',

                de_type10_list_mod             = '{$_POST['de_type10_list_mod']}',

                de_type10_list_row             = '{$_POST['de_type10_list_row']}',

                de_type10_img_width            = '{$_POST['de_type10_img_width']}',

 

                de_type10_img_height           = '{$_POST['de_type10_img_height']}',


/adm/shop_admin/configform.php 쇼핑몰 초기화면 부분이구요

<section id="anc_scf_index">

    <h2 class="h2_frm">쇼핑몰 초기화면</h2>

    <?php echo $pg_anchor; ?>

    <div class="local_desc02 local_desc">

        <p>

            상품관리에서 선택한 상품의 타입대로 쇼핑몰 초기화면에 출력합니다. (상품 타입 히트/추천/최신/인기/할인)<br>

            각 타입별로 선택된 상품이 없으면 쇼핑몰 초기화면에 출력하지 않습니다.        

</p>

    </div>

 

    <div class="tbl_frm01 tbl_wrap">

        <table>

        <caption>쇼핑몰 초기화면 설정</caption>

        <colgroup>

            <col class="grid_4">

            <col>

        </colgroup>

        <tbody>

        <tr>

            <th scope="row">히트상품출력</th>

            <td>

                <label for="de_type1_list_use">출력</label>

                <input type="checkbox" name="de_type1_list_use" value="1" id="de_type1_list_use" <?php echo $default['de_type1_list_use']?"checked":""; ?>>

                <label for="de_type1_list_skin">스킨</label>

                <select name="de_type1_list_skin" id="de_type1_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type1_list_skin']); ?>

                </select>

                <label for="de_type1_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type1_list_mod" value="<?php echo $default['de_type1_list_mod']; ?>" id="de_type1_list_mod" class="frm_input" size="3">

                <label for="de_type1_list_row">출력할 줄 수</label>

                <input type="text" name="de_type1_list_row" value="<?php echo $default['de_type1_list_row']; ?>" id="de_type1_list_row" class="frm_input" size="3">

                <label for="de_type1_img_width">이미지 폭</label>

                <input type="text" name="de_type1_img_width" value="<?php echo $default['de_type1_img_width']; ?>" id="de_type1_img_width" class="frm_input" size="3">

                <label for="de_type1_img_height">이미지 높이</label>

                <input type="text" name="de_type1_img_height" value="<?php echo $default['de_type1_img_height']; ?>" id="de_type1_img_height" class="frm_input" size="3">

            </td>

        </tr>

        <tr>

            <th scope="row">추천상품출력</th>

            <td>

                <label for="de_type2_list_use">출력</label>

                <input type="checkbox" name="de_type2_list_use" value="1" id="de_type2_list_use" <?php echo $default['de_type2_list_use']?"checked":""; ?>>

                <label for="de_type2_list_skin">스킨</label>

                <select name="de_type2_list_skin" id="de_type2_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type2_list_skin']); ?>

                </select>

                <label for="de_type2_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type2_list_mod" value="<?php echo $default['de_type2_list_mod']; ?>" id="de_type2_list_mod" class="frm_input" size="3">

                <label for="de_type2_list_row">출력할 줄 수</label>

                <input type="text" name="de_type2_list_row" value="<?php echo $default['de_type2_list_row']; ?>" id="de_type2_list_row" class="frm_input" size="3">

                <label for="de_type2_img_width">이미지 폭</label>

                <input type="text" name="de_type2_img_width" value="<?php echo $default['de_type2_img_width']; ?>" id="de_type2_img_width" class="frm_input" size="3">

                <label for="de_type2_img_height">이미지 높이</label>

                <input type="text" name="de_type2_img_height" value="<?php echo $default['de_type2_img_height']; ?>" id="de_type2_img_height" class="frm_input" size="3">

            </td>

        </tr>

        <tr>

            <th scope="row">최신상품출력</th>

            <td>

                <label for="de_type3_list_use">출력</label>

                <input type="checkbox" name="de_type3_list_use" value="1" id="de_type3_list_use" <?php echo $default['de_type3_list_use']?"checked":""; ?>>

                <label for="de_type3_list_skin">스킨</label>

                <select name="de_type3_list_skin" id="de_type3_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type3_list_skin']); ?>

                </select>

                <label for="de_type3_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type3_list_mod" value="<?php echo $default['de_type3_list_mod']; ?>" id="de_type3_list_mod" class="frm_input" size="3">

                <label for="de_type3_list_row">출력할 줄 수</label>

                <input type="text" name="de_type3_list_row" value="<?php echo $default['de_type3_list_row']; ?>" id="de_type3_list_row" class="frm_input" size="3">

                <label for="de_type3_img_width">이미지 폭</label>

                <input type="text" name="de_type3_img_width" value="<?php echo $default['de_type3_img_width']; ?>" id="de_type3_img_width" class="frm_input" size="3">

                <label for="de_type3_img_height">이미지 높이</label>

                <input type="text" name="de_type3_img_height" value="<?php echo $default['de_type3_img_height']; ?>" id="de_type3_img_height" class="frm_input" size="3">

            </td>

        </tr>

        <tr>

            <th scope="row">인기상품출력</th>

            <td>

                <label for="de_type4_list_use">출력</label>

                <input type="checkbox" name="de_type4_list_use" value="1" id="de_type4_list_use" <?php echo $default['de_type4_list_use']?"checked":""; ?>>

                <label for="de_type4_list_skin">스킨</label>

                <select name="de_type4_list_skin" id="de_type4_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type4_list_skin']); ?>

                </select>

                <label for="de_type4_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type4_list_mod" value="<?php echo $default['de_type4_list_mod']; ?>" id="de_type4_list_mod" class="frm_input" size="3">

                <label for="de_type4_list_row">출력할 줄 수</label>

                <input type="text" name="de_type4_list_row" value="<?php echo $default['de_type4_list_row']; ?>" id="de_type4_list_row" class="frm_input" size="3">

                <label for="de_type4_img_width">이미지 폭</label>

                <input type="text" name="de_type4_img_width" value="<?php echo $default['de_type4_img_width']; ?>" id="de_type4_img_width" class="frm_input" size="3">

                <label for="de_type4_img_height">이미지 높이</label>

                <input type="text" name="de_type4_img_height" value="<?php echo $default['de_type4_img_height']; ?>" id="de_type4_img_height" class="frm_input" size="3">

            </td>

        </tr>

        <tr>

            <th scope="row">할인상품출력</th>

            <td>

                <label for="de_type5_list_use">출력</label>

                <input type="checkbox" name="de_type5_list_use" value="1" id="de_type5_list_use" <?php echo $default['de_type5_list_use']?"checked":""; ?>>

                <label for="de_type5_list_skin">스킨</label>

                <select name="de_type5_list_skin" id="de_type5_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type5_list_skin']); ?>

                </select>

                <label for="de_type5_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type5_list_mod" value="<?php echo $default['de_type5_list_mod']; ?>" id="de_type5_list_mod" class="frm_input" size="3">

                <label for="de_type5_list_row">출력할 줄 수</label>

                <input type="text" name="de_type5_list_row" value="<?php echo $default['de_type5_list_row']; ?>" id="de_type5_list_row" class="frm_input" size="3">

                <label for="de_type5_img_width">이미지 폭</label>

                <input type="text" name="de_type5_img_width" value="<?php echo $default['de_type5_img_width']; ?>" id="de_type5_img_width" class="frm_input" size="3">

                <label for="de_type5_img_height">이미지 높이</label>

                <input type="text" name="de_type5_img_height" value="<?php echo $default['de_type5_img_height']; ?>" id="de_type5_img_height" class="frm_input" size="3">

            </td>

        </tr>

        </tbody>

        </table>

    </div>

</section>

 

<?php echo preg_replace('#</div>$#i', '<button type="button" class="shop_pc_index">테마설정 가져오기</button></div>', $frm_submit); ?>

 

<section id="anc_scf_index">

    <h2 class="h2_frm">분류별 초기화면</h2>

    <?php echo $pg_anchor; ?>

    <div class="local_desc02 local_desc">

        <p>

            상품관리에서 선택한 상품의 타입대로 분류별 초기화면에 출력합니다. (상품 타입 히트/추천/최신/인기/할인)<br>

            각 타입별로 선택된 상품이 없으면 분류별 초기화면에 출력하지 않습니다.        

</p>

    </div>

 

    <div class="tbl_frm01 tbl_wrap">

        <table>

        <caption>쇼핑몰 초기화면 설정</caption>

        <colgroup>

            <col class="grid_4">

            <col>

        </colgroup>

        <tbody>

        <tr>

            <th scope="row">히트상품출력</th>

            <td>

                <label for="de_type6_list_use">출력</label>

                <input type="checkbox" name="de_type6_list_use" value="1" id="de_type6_list_use" <?php echo $default['de_type6_list_use']?"checked":""; ?>>

                <label for="de_type6_list_skin">스킨</label>

                <select name="de_type6_list_skin" id="de_type6_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type6_list_skin']); ?>

                </select>

                <label for="de_type6_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type6_list_mod" value="<?php echo $default['de_type6_list_mod']; ?>" id="de_type6_list_mod" class="frm_input" size="3">

                <label for="de_type6_list_row">출력할 줄 수</label>

                <input type="text" name="de_type6_list_row" value="<?php echo $default['de_type6_list_row']; ?>" id="de_type6_list_row" class="frm_input" size="3">

                <label for="de_type6_img_width">이미지 폭</label>

                <input type="text" name="de_type6_img_width" value="<?php echo $default['de_type6_img_width']; ?>" id="de_type6_img_width" class="frm_input" size="3">

                <label for="de_type6_img_height">이미지 높이</label>

                <input type="text" name="de_type6_img_height" value="<?php echo $default['de_type6_img_height']; ?>" id="de_type6_img_height" class="frm_input" size="3">

            </td>

        </tr>

        <tr>

            <th scope="row">추천상품출력</th>

            <td>

                <label for="de_type7_list_use">출력</label>

                <input type="checkbox" name="de_type7_list_use" value="1" id="de_type7_list_use" <?php echo $default['de_type7_list_use']?"checked":""; ?>>

                <label for="de_type7_list_skin">스킨</label>

                <select name="de_type7_list_skin" id="de_type7_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type7_list_skin']); ?>

                </select>

                <label for="de_type7_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type7_list_mod" value="<?php echo $default['de_type7_list_mod']; ?>" id="de_type7_list_mod" class="frm_input" size="3">

                <label for="de_type7_list_row">출력할 줄 수</label>

                <input type="text" name="de_type7_list_row" value="<?php echo $default['de_type7_list_row']; ?>" id="de_type7_list_row" class="frm_input" size="3">

                <label for="de_type7_img_width">이미지 폭</label>

                <input type="text" name="de_type7_img_width" value="<?php echo $default['de_type7_img_width']; ?>" id="de_type7_img_width" class="frm_input" size="3">

                <label for="de_type7_img_height">이미지 높이</label>

                <input type="text" name="de_type7_img_height" value="<?php echo $default['de_type7_img_height']; ?>" id="de_type7_img_height" class="frm_input" size="3">

            </td>

        </tr>

        <tr>

            <th scope="row">최신상품출력</th>

            <td>

                <label for="de_type8_list_use">출력</label>

                <input type="checkbox" name="de_type8_list_use" value="1" id="de_type8_list_use" <?php echo $default['de_type8_list_use']?"checked":""; ?>>

                <label for="de_type8_list_skin">스킨</label>

                <select name="de_type8_list_skin" id="de_type8_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type8_list_skin']); ?>

                </select>

                <label for="de_type8_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type8_list_mod" value="<?php echo $default['de_type8_list_mod']; ?>" id="de_type8_list_mod" class="frm_input" size="3">

                <label for="de_type8_list_row">출력할 줄 수</label>

                <input type="text" name="de_type8_list_row" value="<?php echo $default['de_type8_list_row']; ?>" id="de_type8_list_row" class="frm_input" size="3">

                <label for="de_type8_img_width">이미지 폭</label>

                <input type="text" name="de_type8_img_width" value="<?php echo $default['de_type8_img_width']; ?>" id="de_type8_img_width" class="frm_input" size="3">

                <label for="de_type8_img_height">이미지 높이</label>

                <input type="text" name="de_type8_img_height" value="<?php echo $default['de_type8_img_height']; ?>" id="de_type8_img_height" class="frm_input" size="3">

            </td>

        </tr>

        <tr>

            <th scope="row">인기상품출력</th>

            <td>

                <label for="de_type9_list_use">출력</label>

                <input type="checkbox" name="de_type9_list_use" value="1" id="de_type9_list_use" <?php echo $default['de_type9_list_use']?"checked":""; ?>>

                <label for="de_type9_list_skin">스킨</label>

                <select name="de_type9_list_skin" id="de_type9_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type9_list_skin']); ?>

                </select>

                <label for="de_type9_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type9_list_mod" value="<?php echo $default['de_type9_list_mod']; ?>" id="de_type9_list_mod" class="frm_input" size="3">

                <label for="de_type9_list_row">출력할 줄 수</label>

                <input type="text" name="de_type9_list_row" value="<?php echo $default['de_type9_list_row']; ?>" id="de_type9_list_row" class="frm_input" size="3">

                <label for="de_type9_img_width">이미지 폭</label>

                <input type="text" name="de_type9_img_width" value="<?php echo $default['de_type9_img_width']; ?>" id="de_type9_img_width" class="frm_input" size="3">

                <label for="de_type9_img_height">이미지 높이</label>

                <input type="text" name="de_type9_img_height" value="<?php echo $default['de_type9_img_height']; ?>" id="de_type9_img_height" class="frm_input" size="3">

            </td>

        </tr>

        <tr>

            <th scope="row">할인상품출력</th>

            <td>

                <label for="de_type10_list_use">출력</label>

                <input type="checkbox" name="de_type10_list_use" value="1" id="de_type10_list_use" <?php echo $default['de_type10_list_use']?"checked":""; ?>>

                <label for="de_type10_list_skin">스킨</label>

                <select name="de_type10_list_skin" id="de_type10_list_skin">

                    <?php echo get_list_skin_options("^main.[0-9]+\.skin\.php", G5_SHOP_SKIN_PATH, $default['de_type10_list_skin']); ?>

                </select>

                <label for="de_type10_list_mod">1줄당 이미지 수</label>

                <input type="text" name="de_type10_list_mod" value="<?php echo $default['de_type10_list_mod']; ?>" id="de_type10_list_mod" class="frm_input" size="3">

                <label for="de_type10_list_row">출력할 줄 수</label>

                <input type="text" name="de_type10_list_row" value="<?php echo $default['de_type10_list_row']; ?>" id="de_type10_list_row" class="frm_input" size="3">

                <label for="de_type10_img_width">이미지 폭</label>

                <input type="text" name="de_type10_img_width" value="<?php echo $default['de_type10_img_width']; ?>" id="de_type10_img_width" class="frm_input" size="3">

                <label for="de_type10_img_height">이미지 높이</label>

                <input type="text" name="de_type10_img_height" value="<?php echo $default['de_type10_img_height']; ?>" id="de_type10_img_height" class="frm_input" size="3">

            </td>

        </tr>

        </tbody>

        </table>

    </div>

</section>

 

 

<?php echo preg_replace('#</div>$#i', '<button type="button" class="shop_pc_index">테마설정 가져오기</button></div>', $frm_submit); ?>

 

shop/listtype.php 상단이구요 

<?php

include_once('./_common.php');

 

if (G5_IS_MOBILE) {

    include_once(G5_MSHOP_PATH.'/listtype.php');

    return;

}

 

$type = preg_replace("/[\<\>\'\"\\\'\\\"\%\=\(\)\s]/", "", $_REQUEST['type']);

if ($type == 1)      $g5['title'] = '히트상품';

else if ($type == 2) $g5['title'] = '추천상품';

else if ($type == 3) $g5['title'] = '최신상품';

else if ($type == 4) $g5['title'] = '인기상품';

else if ($type == 5) $g5['title'] = '할인상품';

else if ($type == 6) $g5['title'] = '히트상품';

이 질문에 댓글 쓰기 :

답변 1

80번째 줄부터 추가해주신 코드를 사용하기 위해서는

de_type6_list_use 부터 de_type10_img_height  까지의 필드를 g5_config 테이블 상에 추가해주셔야 합니다.

phpmyadmin 에서 사용하고자 하는 필드를 추가해주세요.

 

 

소스와 관계된 부분이 아니구요. 추가한 코드를 실제로 DB에 저장하려면 위에서 지정한 필드를 DB상에 만들어주는 작업을 하셔야 한다는 거에요.
필드를 추가하는 방법은 phpmyadmin 사용법이나 "여분필드 추가" 등의 키워드로 찾아보시기 바랍니다.

답변을 작성하시기 전에 로그인 해주세요.
전체 27
QA 내용 검색

회원로그인

(주)에스아이알소프트 / 대표:홍석명 / (06211) 서울특별시 강남구 역삼동 707-34 한신인터밸리24 서관 1404호 / E-Mail: admin@sir.kr
사업자등록번호: 217-81-36347 / 통신판매업신고번호:2014-서울강남-02098호 / 개인정보보호책임자:김민섭(minsup@sir.kr)
© SIRSOFT