
<link rel="stylesheet" href="img/code43.css" type="text/css">

<table id="__01" width="738" height="97" border="0" cellpadding="0" cellspacing="0">
  <tr> 
    <td> <img src="image/images/cat_middle_01.gif" width="6" height="52" alt=""></td>
    <td> <img src="image/images/cat_middle_02.gif" width="84" height="52" alt=""></td>
    <td background="image/images/cat_middle_03.gif" width="310" height="52"><b><font color=#ff6600> 
      <% = strcat %>
      最新新闻</font></b> <a href=chknews.asp?catid=<% = catid %>>更多相关新闻</a></td>
    <td> <img src="image/images/cat_middle_04.gif" width="7" height="52" alt=""></td>
    <td> <img src="image/images/cat_middle_05.gif" width="81" height="52" alt=""></td>
    <td background="image/images/cat_middle_06.gif" width="250" height="52"><b><font color=#ff6600>推荐 
      <% = strcat %>
      商品</font></b> </td>
  </tr>
  <tr> 
    <td background="image/images/cat_middle_07.gif"> <img src="image/images/cat_middle_07.gif" width="6" height="39" alt=""></td>
    <td colspan="2" background="image/images/cat_middle_08.gif" height="39" valign="top"> 
      <table  width="97%"  cellspacing="0" cellpadding="1" align="center" height="19">
        <%
			
		  rs.open "select top 5 newsid,newsname,newscontent,viewnum,categoryid,adddate from News where categoryid="&catid&" order by adddate desc",conn,1,1
			  if rs.eof and rs.bof then
		   rs.close
			  response.write "<TR><TD height=20 bgcolor=#FFFFFF>&nbsp;暂无此分类新闻</td></tr>"
			  else
			  i=0 
			  do while not rs.eof %>
        <tr class="firstrow"> 
          <td height=29 colspan="2"><img height=11 src="../image/icon_notice.gif" width=17 align=absMiddle border=0> 
            <% response.write "<a href=# onClick=""javascript:window.open('news.asp?id="&rs("newsid")&"','','width=432,height=288,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');return false;"" title="&year(rs("adddate"))&"年"&month(rs("adddate"))&"月"&day(rs("adddate"))&"日发布>"&trim(rs("newsname"))&"</a><br>"
		 %>
          </td>
        </tr>
        <tr > 
          <td height="3" bgcolor="#FFFFFF" background="../image/cate_line.gif"></td>
        </tr>
        <%
				i=i+1
			  if i>=5 then exit do
			  rs.movenext
			  loop 
			  rs.close
		
			  end if%>
      </table>
    </td>
    <td background="image/images/cat_middle_09.gif"> <img src="image/images/cat_middle_09.gif" width="7" height="39" alt=""></td>
    <td colspan="2" background="image/images/cat_middle_10.gif" height="39" valign="top"> 
      <table width="97%" border="0" cellspacing="0" cellpadding="0" align="center" height="19" >
        <%
		
		  rs.open "select top 5 id,name,viewnum from product where categoryid in ("& CatList&") and stock >= 0 and (recommend=1 or recommend = 2) order by adddate desc",conn,1,1
			  if rs.eof and rs.bof then
		   rs.close
			  response.write "<TR><TD height=20 bgcolor=#FFFFFF align=center>暂无此类商品</td></tr>"
			  else
			  i=0 
			  do while not rs.eof %>
        <tr> 
          <td height="29" bgcolor="#FFFFFF"> 
            <%  response.write "&nbsp;<img src=../image/icon_notice.gif><a href=product.asp?id="&rs("id")&" target=_blank title=此商品已被浏览"&rs("viewnum")&"次>"
				if len(trim(rs("name")))>26 then
				response.write left(trim(rs("name")),25)&"..."
				else
				response.write trim(rs("name"))
				end if
				response.write "</a><br>" %>
          </td>
        </tr>
        <tr>
          <td height="3" bgcolor="#FFFFFF" background="../image/cate_line.gif"></td>
        </tr>
        <%
				i=i+1
			  if i>=10 then exit do
			  rs.movenext
			  loop 
			  rs.close
		
			  end if%>
      </table>
    </td>
  </tr>
  <tr> 
    <td colspan="3"> <img src="image/images/cat_middle_11.gif" width="400" height="6" alt=""></td>
    <td> <img src="image/images/cat_middle_12.gif" width="7" height="6" alt=""></td>
    <td colspan="2"> <img src="image/images/cat_middle_13.gif" width="331" height="6" alt=""></td>
  </tr>
</table>
