상품이 없을 경우 구문을 출력하고 싶습니다.(list.10.skin.php)
본문
해당 카테고리에 상품이 없을경우를 출력하고 싶은데요
list.10.skin.php 입니다.
<!-- 상품진열 10 시작 { -->
<?php
if($i == 1) {
$noitem = "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
echo $noitem;
} else {
?>
<div id="main_pd_list" style="margin-bottom: 30px;">
<ul>
<?php
for ($i=1; $row=sql_fetch_array($result); $i++) {
if(!$this->view_it_img) {
Continue;
}
$goods_name = $this->view_it_name ? stripslashes($row['it_name']) : '';
echo '<li class="item"><a href="'.($this->href?$this->href.$row['it_id']:'#').'" class="list_over"><h1 class="pd_info hide">'.cut_str($goods_name, 20, '..').'<br/><span class="price">'.display_price(get_price($row), $row['it_tel_inq']).'</span></h1>'.get_it_image($row['it_id'], $this->img_width, $this->img_height, '', '', $goods_name).'</a></li>';
}
?>
</ul>
</div>
<?php
}
?>
구분자인 $i의 값이 도대체 뭔지 잘 이해가 되지를 않네요..
if문에서 문제가 있는것 같은데 조언 좀 부탁드리겠습니다 ㅜ
!-->
답변을 작성하시기 전에 로그인 해주세요.