it_brand 로 해당 브랜드 제품만 보기

it_brand 로 해당 브랜드 제품만 보기

QA

it_brand 로 해당 브랜드 제품만 보기

본문

it_brand에 

 

1, 2, 3 ,4, 5라는 브랜드가 있을 때 

 

브랜드를 sql 쿼리로 카테고리처럼 불러 오고 

 

전체 제품 리스트를 불러오는거 까지는 했습니다.

 

카테고리에서 1 클릭했을 때 1이라는 브랜드만 보고 싶은데

 

a href="주소.php?" 뒤에

 

&it_brand=1 이나  &sfl=it_brand&stx=1  이라고 하니 되지 않네요.

 

 

 

이 질문에 댓글 쓰기 :

답변 2


shop.lib.php
.
.
.
 // 기본으로 보여지는 필드들
    protected $view_it_id    = false;       // 상품코드
    protected $view_it_img   = true;        // 상품이미지
    protected $view_it_name  = true;        // 상품명
    protected $view_it_basic = true;        // 기본설명
    protected $view_it_price = true;        // 판매가격
    protected $view_it_cust_price = false;  // 소비자가
    protected $view_it_icon = false;        // 아이콘
    protected $view_sns = false;            // SNS
    protected $view_star = false;           // 별점
 
    protected $it_brand = ''; // 추가
.
.
.
 // 외부에서 쿼리문을 넘겨줄 경우에 담아둡니다.
    function set_query($query) {
        $this->query = $query;
    }
하단
    function set_brand($brand) {
        $this->brand = $brand;
    }
추가
.
.
.
if ($this->type) {
                $where[] = " it_type{$this->type} = '1' ";
            }
하단
if ($this->it_brand) {
           $where[] = " it_brand = '{$this->it_brand}' ";
}
추가
list.php
.
.
$list->set_view('it_icon', true);
$list->set_view('sns', true);
쯔음 
$list->set_brand($it_brand);
추가
 
답변을 작성하시기 전에 로그인 해주세요.
전체 123,149 | RSS
QA 내용 검색

회원로그인

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