#120 에 따른 조건 정렬 코드 수정

This commit is contained in:
chicpro
2013-05-03 09:40:57 +09:00
parent bcf6a51990
commit 72e4a9f677
2 changed files with 11 additions and 5 deletions

View File

@ -42,7 +42,7 @@ if ($is_admin)
// 상품 출력순서가 있다면 // 상품 출력순서가 있다면
if ($sort != "") { if ($sort != "") {
$order_by = $sort . " , "; $order_by = $sort . ' '.$sortodr. ' , ';
} }
// 상품 (하위 분류의 상품을 모두 포함한다.) // 상품 (하위 분류의 상품을 모두 포함한다.)
@ -91,7 +91,10 @@ if ($is_admin)
echo '<div>'.$error.'</div>'; echo '<div>'.$error.'</div>';
} }
$qstr1 .= 'ca_id='.$ca_id.'&amp;skin='.$skin.'&amp;ev_id='.$ev_id.'&amp;sort='.$sort; $qstr1 .= 'ca_id='.$ca_id;
if($skin)
$qstr1 .= '&amp;skin='.$skin;
$qstr1 .='&amp;ev_id='.$ev_id.'&amp;sort='.$sort.'&amp;'.$sortodr;
echo get_paging($config['cf_write_pages'], $page, $total_page, $_SERVER['PHP_SELF'].'?'.$qstr1.'&amp;page='); echo get_paging($config['cf_write_pages'], $page, $total_page, $_SERVER['PHP_SELF'].'?'.$qstr1.'&amp;page=');
?> ?>

View File

@ -1,7 +1,10 @@
<?php <?php
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가 if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
$sct_sort_href = $_SERVER['PHP_SELF'].'?ca_id='.$ca_id.'&amp;skin='.$skin.'&amp;ev_id='.$ev_id.'&amp;sort='; $sct_sort_href = $_SERVER['PHP_SELF'].'?ca_id='.$ca_id;
if($skin)
$sct_sort_href .= '&amp;skin='.$skin;
$sct_sort_href .= '&amp;ev_id='.$ev_id.'&amp;sort=';
?> ?>
<section id="sct_sort"> <section id="sct_sort">
@ -11,8 +14,8 @@ $sct_sort_href = $_SERVER['PHP_SELF'].'?ca_id='.$ca_id.'&amp;skin='.$skin.'&amp;
</div> </div>
<ul> <ul>
<li><a href="<?php echo $sct_sort_href; ?>it_amount&amp;sortodr=desc" class="btn01">낮은가격순</a></li> <li><a href="<?php echo $sct_sort_href; ?>it_amount&amp;sortodr=asc" class="btn01">낮은가격순</a></li>
<li><a href="<?php echo $sct_sort_href; ?>it_amount&amp;sortodr=asc" class="btn01">높은가격순</a></li> <li><a href="<?php echo $sct_sort_href; ?>it_amount&amp;sortodr=desc" class="btn01">높은가격순</a></li>
<li><a href="<?php echo $sct_sort_href; ?>it_name&amp;sortodr=asc" class="btn01">상품명순</a></li> <li><a href="<?php echo $sct_sort_href; ?>it_name&amp;sortodr=asc" class="btn01">상품명순</a></li>
<li><a href="<?php echo $sct_sort_href; ?>it_type1&amp;sortodr=desc" class="btn01">히트상품</a></li> <li><a href="<?php echo $sct_sort_href; ?>it_type1&amp;sortodr=desc" class="btn01">히트상품</a></li>
<li><a href="<?php echo $sct_sort_href; ?>it_type2&amp;sortodr=desc" class="btn01">추천상품</a></li> <li><a href="<?php echo $sct_sort_href; ?>it_type2&amp;sortodr=desc" class="btn01">추천상품</a></li>