<?php
		include("header.tpl.php");
		include("bodytop.tpl.php"); 
?>
<script language=javascript src="./engine/js/popwin.js"></script>
<div class="clear"></div>
<div id="productmenu">
		<div class="menuhead"></div>
		<div class="menucontent">
			<ul class="productmenu_ul">
			<li class="logo"></li>
			<?php foreach($maincategory as $key => $val){?>
			<li class="category"><img src="./images/common/arrow_03.gif"> <a href="productdisplay.php?pid=<?php echo $val['pid']?>&categoryid=<?php echo $key?>"><?php echo $val['categorytitle']?></a>
			</li>
			<?php if(isset($subcategory[$key])){?>
				<?php foreach($subcategory[$key] as $subkey => $subval){?>
				<li class="sub"><img src="./images/common/arrow_03.gif"> <a class="font_12" href="productdisplay.php?pid=<?php echo $subval['pid']?>&categoryid=<?php echo $subkey?>"><?php echo $subval['categorytitle']?></a>
				</li>
				<?php }?>
			<?php }?>
			<?php }?>
			</ul>
			<div class="menubottom"></div>
		</div>
	</div>
	<div id="productlist">
		<table>
		<tr>
		<td width="30">	<img src="<?php echo $templatedir?>images/ico_1.gif"></td>
		<td align="left"> <a href="index.php">网站首页</a> >> <?php echo $productname?></td>
		</tr>
		</table>
		<hr>
			<form id="form_productlist" method="post" >
			<div class="productleft"></div>
			<div class="productlist_body">
			<ul class="productlist_ul">
			<li class="category">
				<div class="title_left"></div>
				<div class="title_body">
				<?php echo $productname?>
				</div>
				<div class="title_right"></div>
				</li>
			<?php foreach ($topproducts as $key => $topproduct) {?>
			<li class="title">
			<?php if($pervalue{16}){ ?>
			<input type="checkbox" name="top_product_check[]" id="top_product_check_<?php echo $key?>" value="<?php echo $topproduct['productid']?>">
			<a href="post.php?ipost=modifyproduct&mid=<?php echo $topproduct['productid']?>">[修改]</a>
			<? }?>
			<font color="red">产品推荐</font>
			 <font color=<?php echo $productidentification[$topproduct['tag']][0]?>>  
			<?php echo $productidentification[$topproduct['tag']][1]?></font> | <a href="viewproduct.php?productid=<?php echo $topproduct['productid']?>"><?php echo height_light($topproduct['producttitle'],$topproduct['hlight'],$hlightway)?></a></li>
				
<li class="logoimg">
<div>
 <a href="viewproduct.php?productid=<?php echo $topproduct['productid']?>">
	<img src="<?php echo $topproduct['logo']?>" >
 </a>
</div>
<span>
     <img src="images/common/product_enlarge_icon.gif" />
	<a href="javascript:void(0)" onclick="popwindows('<?php echo $topproduct['storename']?>',1,0)">点击放大图片</a></span>
</li>

				<li class="prointro">
				<cite>产品简介</cite>
				<span><?php echo $topproduct['productintro']?></span>
				</li>
				<li class="space"></li>
			<?php }?>
			<?php foreach ($products as $key => $product) {?>
			<li class="title">
			<?php if($pervalue{16}){ ?>
			<input type="checkbox" name="product_check[]" id="product_check_<?php echo $key?>" value="<?php echo $product['productid']?>">
			<a href="post.php?ipost=modifyproduct&mid=<?php echo $product['productid']?>">[修改]</a>
			<? }?>
			 <font color=<?php echo $productidentification[$product['tag']][0]?>>  
			<?php echo $productidentification[$product['tag']][1]?>
			</font> |	
			<a href="viewproduct.php?productid=<?php echo $product['productid']?>">
			<?php echo height_light($product['producttitle'],$product['hlight'],$productcategory[$product['categoryid']]['hlightway'])?>
			</a></li>
				
<li class="logoimg">
<div>
	<a href="viewproduct.php?productid=<?php echo $product['productid']?>">
	<img src="<?php echo $product['logo']?>" ></a>
</div>
<span>
	<img src="images/common/product_enlarge_icon.gif" /> 
	<a href="javascript:void(0)" onclick="popwindows('<?php echo $product['storename']?>',1,0)">点击放大图片</a></span>
</li>

				<li class="prointro">
				<cite>产品简介</cite>
				<span><?php echo $product['productintro']?></span>
				</li>
				<li class="space"></li>
			<?php }?>
			</ul>
			</div>
			<div class="productright"></div>
			<div class="clear"></div>
			<div id="moveform" style="display:none;">
					<select id="move_select_cid" name="move_select_cid">
						<option value="0,0" selected >产品根分类</option >
						<?php	echo $echoselectform;?>
					</select> 
					<button onclick="psetting('post.php?','move',<?php echo $pid?>,<?php echo $categoryid?>)"> 开始转移 </button> 
			</div>
			</form>
				<div class="clear"></div>
			<?php if($pervalue{16}){ ?>
				<div id="toolbox">
					<input type="checkbox" name="product_check_all" id="product_check_all" onclick="checkall_onclick('product')"> 全选 
					<button onclick="psetting('post.php?','settop',<?php echo $pid?>,<?php echo $categoryid?>)">产品推荐</button>
					<button onclick="psetting('post.php?','unsettop',<?php echo $pid?>,<?php echo $categoryid?>)"> 取消推荐</button>
					<button onclick="psetting('post.php?','priority',<?php echo $pid?>,<?php echo $categoryid?>)"> 产品优先</button>
					<button onclick="psetting('post.php?','unpriority',<?php echo $pid?>,<?php echo $categoryid?>)"> 取消优先</button>
					<button onclick="psetting('post.php?','sethlight',<?php echo $pid?>,<?php echo $categoryid?>)"> 高亮显示</button>
					<button onclick="psetting('post.php?','unsethlight',<?php echo $pid?>,<?php echo $categoryid?>)"> 取消高亮</button>
					<button onclick="psetting('post.php?','delete',<?php echo $pid?>,<?php echo $categoryid?>)"> 删除产品</button>
					<button onclick='showmoveform()'> 转移产品</button>
				</div>
			<?php }?>
		</div>
</div>
				<div class="pages_btns font_14">
				<?php echo $multipage?>
				</div>

	<div class="clear"></div>

<?php
include("tail.tpl.php"); 
?>