목록 페이징 링크 배열 재질문

목록 페이징 링크 배열 재질문

QA

목록 페이징 링크 배열 재질문

본문

페이징 링크를 아래처럼 작업 후

초기 검색 할 때 체크박스를 체크 하든지 안하든지 초기 검색은 정상적으로 나오는데

페이징을 넘기면 검색값이 나오질 않는데요..

 

어디가 잘못된 걸까요?

아래 볼드부분을 빼고 검색 하면 페이징 넘겨도 잘 되는데 볼드부분이 있으면 기본 검색후에도 페이징 넘기면 값이 나오질 않네요.. 어떻게 수정을 해줘야 할까요

 

$qstr1 = "od_status=".urlencode($od_status)."&od_settle_case=".urlencode($od_settle_case)."&od_misu=$od_misu&od_cancel_price=$od_cancel_price&od_refund_price=$od_refund_price&od_receipt_point=$od_receipt_point&od_coupon=$od_coupon&fr_date=$fr_date&to_date=$to_date&sel_field=$sel_field&search=$search&save_search=$search&depth1[0]=$depth1[0]&depth1[1]=$depth1[1]&depth1[2]=$depth1[2]&depth2[0]=$depth2[0]&depth2[1]=$depth2[1]&depth2[2]=$depth2[2]&depth2[3]=$depth2[3]&depth3[0]=$depth3[0]&depth3[1]=$depth3[1]&depth4[0]=$depth4[0]&depth4[1]=$depth4[1]&depth4[2]=$depth4[2]&depth4[3]=$depth4[3]&fr_date2=$fr_date2&to_date2=$to_date2&fr_date3=$fr_date3&to_date3=$to_date3";

 

검색시에 사용되는 배열 체크박스 html


<div class="sch_last" style="border:1px solid #ccc">
    <ul style="margin:0 0 10px">
        <li>
            <strong class="sch_long">1차분류</strong>
            <input type="checkbox" name="depth1[0]" value="80" id="1_1depth" <?php if($depth1[0] == '80') { echo "checked"; } ?>> <label for="1_1depth">과일골라담기</label>
            <input type="checkbox" name="depth1[1]" value="70" id="1_3depth" <?php if($depth1[1] == '70') { echo "checked"; } ?>> <label for="1_3depth">과일1회이용권</label>
            <input type="checkbox" name="depth1[2]" value="60" id="1_2depth" <?php if($depth1[2] == '60') { echo "checked"; } ?>> <label for="1_2depth">과일정기배송</label>
        </li>
        <li>
            <strong class="sch_long">주문일자</strong>
            <input type="text" id="fr_date2"  name="fr_date2" value="<?php echo $fr_date2; ?>" class="frm_input" size="10" maxlength="10"> ~
            <input type="text" id="to_date2"  name="to_date2" value="<?php echo $to_date2; ?>" class="frm_input" size="10" maxlength="10">
            <button type="button" onclick="javascript:set_date2('전체');">전체</button>
        </li>
    </ul>
    <ul>
        <li>
            <strong class="sch_long">2차분류</strong>
            <input type="checkbox" name="depth2[0]" value="실속 정기배송(한달 4회)" id="2_1depth" <?php if($depth2[0] == '실속 정기배송(한달 4회)') { echo "checked"; } ?>> <label for="2_1depth">실속 정기배송(한달 4회)</label>
            <input type="checkbox" name="depth2[1]" value="실속 정기배송(한달 2회)" id="2_2depth" <?php if($depth2[1] == '실속 정기배송(한달 2회)') { echo "checked"; } ?>> <label for="2_2depth">실속 정기배송(한달 2회)</label>
            <input type="checkbox" name="depth2[2]" value="채움 정기배송(한달 4회)" id="2_3depth" <?php if($depth2[2] == '채움 정기배송(한달 4회)') { echo "checked"; } ?>> <label for="2_3depth">채움 정기배송(한달 4회)</label>
            <input type="checkbox" name="depth2[3]" value="채움 정기배송(한달 2회)" id="2_4depth" <?php if($depth2[3] == '채움 정기배송(한달 2회)') { echo "checked"; } ?>> <label for="2_4depth">채움 정기배송(한달 2회)</label>
        </li>
        <li>
            <strong class="sch_long">지역</strong>
            <input type="checkbox" name="depth3[0]" value="서울" id="depth3_1" <?php if($depth3[0] == '서울') { echo "checked"; } ?>> <label for="depth3_1">서울</label>
            <input type="checkbox" name="depth3[1]" value="지방" id="depth3_2" <?php if($depth3[1] == '지방') { echo "checked"; } ?>> <label for="depth3_2">지방</label>
        </li>
        <li>
            <strong class="sch_long">요일</strong>
            <input type="checkbox" name="depth4[0]" value="화요일" id="depth4_1" <?php if($depth4[0] == '화요일') { echo "checked"; } ?>> <label for="depth4_1">화요일</label>
            <input type="checkbox" name="depth4[1]" value="수요일" id="depth4_2" <?php if($depth4[1] == '수요일') { echo "checked"; } ?>> <label for="depth4_2">수요일</label>
            <input type="checkbox" name="depth4[2]" value="목요일" id="depth4_3" <?php if($depth4[2] == '목요일') { echo "checked"; } ?>> <label for="depth4_3">목요일</label>
            <input type="checkbox" name="depth4[3]" value="금요일" id="depth4_4" <?php if($depth4[3] == '금요일') { echo "checked"; } ?>> <label for="depth4_4">금요일</label>
        </li>
        <li style="margin:15px 0 0">
            
            <strong style="margin-left:30px">정기배송일자</strong>
            <input type="text" id="fr_date3"  name="fr_date3" value="<?php echo $fr_date3; ?>" class="frm_input" size="10" maxlength="10"> ~
            <input type="text" id="to_date3"  name="to_date3" value="<?php echo $to_date3; ?>" class="frm_input" size="10" maxlength="10">
            <button type="button" onclick="javascript:set_date3('전체');">전체</button>
        </li>
    </ul>
</div>

이 질문에 댓글 쓰기 :

답변 2

왜 배열을 쓰시는지 이유를 모르겠네요...

이렇게 하면 안되나요?

 

$qstr1 = "od_status=".urlencode($od_status)."&od_settle_case=".urlencode($od_settle_case)."&od_misu=$od_misu&od_cancel_price=$od_cancel_price&od_refund_price=$od_refund_price&od_receipt_point=$od_receipt_point&od_coupon=$od_coupon&fr_date=$fr_date&to_date=$to_date&sel_field=$sel_field&search=$search&save_search=$search&depth1=$depth1&depth2=$depth2&depth3=$depth3&depth4=$depth4&fr_date2=$fr_date2&to_date2=$to_date2&fr_date3=$fr_date3&to_date3=$to_date3

 



<div class="sch_last" style="border:1px solid #ccc">
    <ul style="margin:0 0 10px">
        <li>
            <strong class="sch_long">1차분류</strong>
            <input type="checkbox" name="depth1" value="80" id="1_1depth" <?php if($depth1 == '80') { echo "checked"; } ?>> <label for="1_1depth">과일골라담기</label>
            <input type="checkbox" name="depth1" value="70" id="1_3depth" <?php if($depth1 == '70') { echo "checked"; } ?>> <label for="1_3depth">과일1회이용권</label>
            <input type="checkbox" name="depth1" value="60" id="1_2depth" <?php if($depth1 == '60') { echo "checked"; } ?>> <label for="1_2depth">과일정기배송</label>
        </li>
        <li>
            <strong class="sch_long">주문일자</strong>
            <input type="text" id="fr_date2"  name="fr_date2" value="<?php echo $fr_date2; ?>" class="frm_input" size="10" maxlength="10"> ~
            <input type="text" id="to_date2"  name="to_date2" value="<?php echo $to_date2; ?>" class="frm_input" size="10" maxlength="10">
            <button type="button" onclick="javascript:set_date2('전체');">전체</button>
        </li>
    </ul>
    <ul>
        <li>
            <strong class="sch_long">2차분류</strong>
            <input type="checkbox" name="depth2" value="실속 정기배송(한달 4회)" id="2_1depth" <?php if($depth2 == '실속 정기배송(한달 4회)') { echo "checked"; } ?>> <label for="2_1depth">실속 정기배송(한달 4회)</label>
            <input type="checkbox" name="depth2" value="실속 정기배송(한달 2회)" id="2_2depth" <?php if($depth2 == '실속 정기배송(한달 2회)') { echo "checked"; } ?>> <label for="2_2depth">실속 정기배송(한달 2회)</label>
            <input type="checkbox" name="depth2" value="채움 정기배송(한달 4회)" id="2_3depth" <?php if($depth2 == '채움 정기배송(한달 4회)') { echo "checked"; } ?>> <label for="2_3depth">채움 정기배송(한달 4회)</label>
            <input type="checkbox" name="depth2" value="채움 정기배송(한달 2회)" id="2_4depth" <?php if($depth2 == '채움 정기배송(한달 2회)') { echo "checked"; } ?>> <label for="2_4depth">채움 정기배송(한달 2회)</label>
        </li>
        <li>
            <strong class="sch_long">지역</strong>
            <input type="checkbox" name="depth3" value="서울" id="depth3_1" <?php if($depth3 == '서울') { echo "checked"; } ?>> <label for="depth3_1">서울</label>
            <input type="checkbox" name="depth3" value="지방" id="depth3_2" <?php if($depth3 == '지방') { echo "checked"; } ?>> <label for="depth3_2">지방</label>
        </li>
        <li>
            <strong class="sch_long">요일</strong>
            <input type="checkbox" name="depth4" value="화요일" id="depth4_1" <?php if($depth4 == '화요일') { echo "checked"; } ?>> <label for="depth4_1">화요일</label>
            <input type="checkbox" name="depth4" value="수요일" id="depth4_2" <?php if($depth4 == '수요일') { echo "checked"; } ?>> <label for="depth4_2">수요일</label>
            <input type="checkbox" name="depth4" value="목요일" id="depth4_3" <?php if($depth4 == '목요일') { echo "checked"; } ?>> <label for="depth4_3">목요일</label>
            <input type="checkbox" name="depth4" value="금요일" id="depth4_4" <?php if($depth4 == '금요일') { echo "checked"; } ?>> <label for="depth4_4">금요일</label>
        </li>
        <li style="margin:15px 0 0">
            
            <strong style="margin-left:30px">정기배송일자</strong>
            <input type="text" id="fr_date3"  name="fr_date3" value="<?php echo $fr_date3; ?>" class="frm_input" size="10" maxlength="10"> ~
            <input type="text" id="to_date3"  name="to_date3" value="<?php echo $to_date3; ?>" class="frm_input" size="10" maxlength="10">
            <button type="button" onclick="javascript:set_date3('전체');">전체</button>
        </li>
    </ul>
</div>


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

회원로그인

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