<?php
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가

if($is_related == 'board') { 
	$list['thumb'] = amina_thumb($list, 50, 50, '', 'none', 's', true);
?>
	<div class="related">
	<ul>
		<li class="mbody">
			<?php echo $list['thumb']; ?>
			<p><a href="<?php echo $list['href']; ?>" target="_top"><b><?php echo $list['subject']; ?></b></a>
			    <?php if ($list['comment_cnt']) {?> <span class="cmt"><?php echo $list['comment_cnt']; ?></span><?php } ?>
			</p>
			<ul class="bar11">
				<li class="first"><?php echo $list['bo_subject']; ?></li>
				<?php if($list['ca_name']) { ?>
					<li><?php echo $list['ca_name']; ?></span></li>
				<?php } ?>
				<li><?php echo $list['wr_name']; ?></span></li>
				<li>조회 <span class="cnt"><?php echo $list['wr_hit']; ?></span></li>
				<li><span class="cnt"><?php echo date("Y.m.d", strtotime($list['wr_datetime'])); ?></span></li>
			</ul>
		</li>
	</ul>
	<div class="clear"></div>
	</div>
<?php } else if($is_related == 'youngcart') { ?>
	<div class="related">
	<ul>
		<li class="mbody">
			<div class="thumb">
				<a href="<?php echo $g4['shop_path']; ?>/item.php?it_id=<?php echo $it['it_id']; ?>" target="_top"><img src="<?php echo bthumbnail(G4_DATA_PATH."/item/".$it['it_id']."_l1", 50, 50); ?>" alt="" /></a>
			</div>
			<p><b><a href="<?php echo $g4['shop_path']; ?>/item.php?it_id=<?php echo $it['it_id']; ?>" target="_top"><?php echo it_name_icon($it, stripslashes($it['it_name']), false); ?></a></b></p>
			<ul class="bar11">
				<?php if($it['it_use']) { 
						if($it['it_tel_inq']) {
							echo '<li class="first">전화문의</li>';
						} else {
							echo '<li class="first">';
							if ($it['it_cust_amount']) echo '<del>'.number_format($it['it_cust_amount'], 0).'원</del> → ';
							echo '<span class="amount">'.number_format(get_amount($it), 0).'원</span>';
							echo '</li>';
						}
					?>
					<li><span class="cnt"><?php echo number_format($it['it_point']); ?></span> 포인트 적립</li>
				<?php } else { ?>
					<li class="first">판매가 종료된 상품입니다.</li>
				<?php } ?>
			</ul>
		</li>
	</ul>
	<div class="clear"></div>
	</div>
<?php } ?>