<!--#include file="Head.asp"-->
<div align="center">
  <table width="950" border="0" cellspacing="0" cellpadding="0" class="Outside">
    <tr>
	<td width="240" valign="top">
	<table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td><table width="215" border="0" align="center" cellpadding="1" cellspacing="0">
            <tr>
              <td width="215" height="38" background="../Images/VoteMenu.jpg"><div style="margin-left:90px;"><b><font color="#FFFFFF">评选导航</font></b></div></td>
            </tr>
          </table></td>
        </tr>
        <tr>
          <td >&nbsp;</td>
        </tr>
        <tr>
          <td align="center" ></td>
        </tr>
        <tr>
          <td>
		  <div style="margin-left:20px;">
			  <%
			  Datafrom="ameav_ProductSort"
			  ListView="Amvote"
			  ListSort(0)
			  %>
			</div>
		  </td>
        </tr>
      </table>
	  <!--#include file="tabmenu.asp"-->
	  
	  </td>
      <td width="1" valign="top" bgcolor="#dd0000"></td>
	<td width="690"  valign="top">
	  <table width="100%" border="0" cellspacing="0" cellpadding="0">
	    <tr>
	      <td width="26" height="32" align="center" bgcolor="#FFFFFF">&nbsp;</td>
            <td width="674" bgcolor="#FFFFFF" class="Location"><a href="../index.asp">首页</a><img src="../Images/Arrow_02.gif" width="13" height="12" align="absmiddle"><a href='AmvoteList.asp'>评选品牌</a>
              <% if not request.QueryString("SortID")="" then WebLocation(request.QueryString("SortID")) %></td>
            <td width="80" bgcolor="#FFFFFF" class="Location">          </td>
          </tr>
	    </table>
	   <table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td width="30" height="12" bgcolor="#FFFFFF"></td>
            <td bgcolor="#FFFFFF"></td>
            <td width="30" bgcolor="#FFFFFF"></td>
          </tr>
          <tr>
            <td bgcolor="#FFFFFF">&nbsp;</td>
            <td bgcolor="#FFFFFF"><%=WebContent()%></td>
            <td bgcolor="#FFFFFF">&nbsp;</td>
          </tr>
        </table>

<table width="100%" height="155" border="0" align="center" cellpadding="0" cellspacing="0" >
	<%	  
	id=Request.QueryString("id")
	%>
  <tr>
    <td width="29" height="32" align="center" valign="middle" bgcolor="#FFFFFF" class="STYLE3" style="line-height: 150%">&nbsp;</td>
    <td width="751" height="25" align="left" valign="middle" bgcolor="#FFFFFF" class="STYLE3" style="line-height: 150%">最新品牌评论<img src="../Images/Arrow_02.gif" width="13" height="12" align="absmiddle"><a href="Productotal.asp?id=<%=id%>" target="_blank"><span class="Location"></span>查看所有评论 </a></td>
  </tr>
  <tr>
    <td height="70" colspan="2" align="left" valign="top" bgcolor="#FFFFFF" class="STYLE3" style="line-height: 150%"><table width="100%" border="0" cellpadding="0" cellspacing="0" >
      <%
	  function showstring(fString)
	if not isnull(fString) then
		fString = replace(fString, ">", "&gt;")
		fString = replace(fString, "<", "&lt;")
		fString = replace(fString, chr(13), "")
		fString = replace(fString, chr(10), "<br />")
		fString = replace(fString, chr(34), "&quot;")
		fString = replace(fString, chr(39), "&#39;")
		fString = replace(fString, "script", "&#115cript")
		showstring = fString
	end if
	end function
	dim id
	id=Request.QueryString("id")
	Set rs=server.CreateObject("Adodb.Recordset")
	sql="Select top 5 * from ameav_pl where sh=1 and pid="&id&" order by addtime desc"
	rs.Open sql,conn,1,1
	if rs.eof then
	%>
  <tr>
    <td colspan="2" align="center" valign="middle" height="30">暂无评论</td>
  </tr>
 <%
end if
do while not rs.eof 
%>
      <tr>
        <td width="28" height="40" align="center" valign="middle"></td>
        <td width="690" align="left" valign="top" class="STYLE3" style="line-height: 150%">
            评论信息：
            <%=showstring(rs("info"))%><br />
            评论人：<%=rs("nick")%>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;QQ/MSN：<%=rs("qq")%>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;评论时间：<%=rs("addtime")%></td>
      </tr>
      <%
rs.MoveNext
Loop
rs.Close
Set rs=Nothing
%>
    </table></td>
  </tr>
</table>

  <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#FFFFFF" bgcolor="#D4D0C8">
  <form id="form12" name="form12" method="post" action="Productpl_do.asp?id=<%=id%>">
    <tr>
      <td height="25" colspan="2"  bgcolor="#FFFFFF" class="STYLE3"><a name="pl">&nbsp;&nbsp;&nbsp;</a>发表评论</td>
    </tr>
    <tr>
      <td width="139" height="42" bgcolor="#FFFFFF">　　昵　称： </td>
      <td width="541" bgcolor="#FFFFFF"><input name="nick" type="text" class="STYLE4" id="nick" size="15" maxlength="20" />
        &nbsp;&nbsp;QQ/MSN：
      <input name="qq" type="text" class="STYLE4" id="qq" size="15" maxlength="50" />
      &nbsp;&nbsp;验证码：
      <input name='validatecode' type='text' size='5' style="ime-mode:disabled" />
      <img src='../Include/CheckCode/validatecode.asp' align='absmiddle' border='0' /></td>
    </tr>
    <tr>
      <td height="85" valign="top" bgcolor="#FFFFFF">　　内　容： </td>
      <td height="85" valign="top" bgcolor="#FFFFFF"><textarea name="info" cols="58" rows="5" id="info"></textarea></td>
    </tr>
    <tr>
      <td height="49" valign="top" bgcolor="#FFFFFF">&nbsp;</td>
      <td height="49" align="center" bgcolor="#FFFFFF"><br />
          <input name="Submit" type="submit" class="MemLogin" value="发表评论" />
        &nbsp;
          <input name="Submit2" type="reset" class="MemLogin" value="重写" /></td>
    </tr>
	</form>
  </table>
	
	</td>
    </tr>
  </table>
</div>
<%
Function WebLocation(ID)
  Dim rs,sql,LocationText,sumvote,start
  Set rs=server.CreateObject("adodb.recordset")
  sql="Select * From Ameav_ProductSort where ViewFlag  and ID="&ID
  rs.open sql,conn,1,1
  if rs.bof and rs.eof then
    response.write "<img src='../Images/Arrow_02.gif' align='absmiddle'>错误"
    exit function
  end if
  LocationText="<img src='../Images/Arrow_02.gif' align='absmiddle'><a href='AmvoteList.asp?SortID="&rs("ID")&"&SortPath="&rs("SortPath")&"'>"&rs("SortName")&"</a>"
  if rs("ParentID")<>0 then WebLocation rs("ParentID")
  response.write LocationText
End Function
function WebContent()
  dim ID,renid
  
  ID=request.QueryString("ID")
  if ID="" or (not isnumeric(ID)) then
    response.write "<div align='center'>数据读取异常错误</div>"
    exit function
  end if
  set rs = server.createobject("adodb.recordset")
  sql="select * from ameav_Products where ViewFlag  and ID="&ID
  rs.open sql,conn,1,3
  response.write"<table width='100%' border='0' cellspacing='0' cellpadding='0'>"
  if rs.bof and rs.eof then
    response.write "<tr><td>暂无相关信息</td></tr>"
  else
    if ViewNoRight(rs("GroupID"),rs("Exclusive")) then
      dim BigPicPath,ProductName,ProductNo,ClickNumber,ProductModel
	  	  BigPicPath=HtmlSmallPic(rs("GroupID"),rs("BigPic"),rs("Exclusive"))
	      if StrLen(rs("ProductName"))<=18 then
            ProductName=rs("ProductName")
	      else 
	        ProductName=StrLeft(rs("ProductName"),16)
	      end if
		  ProductNo=rs("ProductNo")
          ProductModel=rs("ProductModel")
		  ClickNumber=rs("ClickNumber")
	  sumvote=rs("hits")
	  if sumvote<1000 then
	  start=1
	  elseif sumvote>1000 and sumvote<3000 then
	  start=2
	  elseif sumvote>3000 and sumvote<6000 then
	  start=3
	  elseif sumvote>6000 and sumvote<15000 then
	  start=4
	  elseif sumvote>15000 then	
	  start=5
	  end if
      response.write "<tr><td  valign='top' align=center><a name=vote></a>"
	  response.write "<div id='append_parent'></div>"
	  %>
	  <a href='#zoom'><img onClick="zoom(this, '<%=BigPicPath%>');" src="<%=BigPicPath%>" onload="javascript:if(this.width>1000)this.width=1000"  border='0' width='500' height='350'></a>
	  <%
	  response.Write "</td></tr>"		   
	  response.write "<tr><td height='10'></td></tr>"
	  response.write "<tr><td height='10' align=center>出品：<a href='"&ProductNo&"' target=_blank>"&ProductModel&"</a>&nbsp;&nbsp;&nbsp;&nbsp;投票数：<font color=red>"&ClickNumber&"票</font>&nbsp;&nbsp;&nbsp;&nbsp;标题：<b>"&ProductName&"</b>&nbsp;&nbsp;&nbsp;&nbsp;"
	  response.write "星级指数：<img src='../Images/"&start&"star.gif'  />"
	  response.write"&nbsp;&nbsp;&nbsp;&nbsp;人气数：<font color=red>"&rs("Hits")&"次</font>"
	  response.write "&nbsp;&nbsp;&nbsp;&nbsp;<a href='AmvoteView.asp?ID="&rs("id")&"&SortID="&rs("SortID")&"&#pl'>评论</a></td></tr>"
	  response.write "<tr><td height='22' ></td>"
	  response.write "<td  align='center'></td></tr>"	  
	  response.write "<tr><td >"
	  response.write"<table width='100%' border='0' cellpadding='0' cellspacing='0'>"
	  response.write"<form  name='form1' method='post' action='PhotoVing.asp?Action=ving'>"
	  response.write"<tr>"
	  response.write"<td height='25' align='left'>验证码：<input name='CheckCode' type='text' class='input' id='CheckCode' style='width: 80px;' maxlength='10' /><img id='checkcode' src='../Include/CheckCode/CheckCode.asp' style='border: 1px solid #ffffff' /></td>"
	  response.write"<td align='center'><input type=hidden name='id' value='"&rs("id")&"'><input type=hidden name='uname' value='"&rs("ProductName")&"'><input type=hidden name=renid value='"&RndNumber(10000,1000)&"'><input type='submit' name='Submit' value='投此一票' class=button ></td>"
	  response.write"</tr></form></table>"
	  response.write"</td>"
	  response.write "<tr><td height='22' ><b>品牌简述：</b></td>"
	  response.write "<td  align='center'></td></tr>"
	  response.write "<tr><td colspan='2' height='12'></td></tr>"
	  response.write "<tr><td colspan='2' width='604'>"&rs("Content")&"</td></tr>"
	else
      response.write "<tr><td colspan='2'><hr width='100%' size='1' noshade='noshade' color='#FF0000'></td></tr>"
      response.write "<tr><td width='424'>名称：<font style='font-weight: bold;color: #1874CD'>"&rs("ProductName")&"</font></td><td width='180'>时间："&rs("AddTime")&"</td></tr>"
 	  response.write "<tr><td colspan='2'><hr width='100%' size='1' noshade='noshade' color='#FF0000'><div align='center'><img src='../Images/NoRight.jpg'></div></td></tr>"
	end if
    response.write "<tr><td class='ListTitle' colspan='2'></td></tr>"
    response.write "<tr><td></td>"
	response.write "<td align='right'><a href='#TOP'><img src='../Images/Button_top_01.gif' align='absbottom' border='0'></a></td></tr>" 
	rs("Hits")=rs("Hits")+1
	rs.update	   
  end if
 response.write "<tr><td colspan='2'><hr width='100%' size='1' noshade='noshade' color='#FF0000'></td></tr><tr><td colspan='2'>"
  rs.close
  Dim IDmax,IDmin
  	  IDmax=ID+1
	set rs = server.createobject("adodb.recordset")
	sql="select * from ameav_Products where ViewFlag  and ID="&IDmax
	rs.open sql,conn,1,1
	if not rs.eof then
		 Response.Write "上一篇：<a href='?id="&Idmax&"&SortID="&rs("SortID")&"'>"&rs("ProductName")&"</a><br>"
	else
		Response.Write "上一篇：暂无评选<br>"
	end if
	rs.close
	IDmin=ID-1
	set rs = server.createobject("adodb.recordset")
	sql="select * from ameav_Products where ViewFlag  and ID="&IDmin
	rs.open sql,conn,1,1
	if not rs.eof then
		 Response.Write "下一篇：<a href='?id="&IDmin&"&SortID="&rs("SortID")&"'>"&rs("ProductName")&"</a>"
	else
		Response.Write "下一篇：暂无评选"
	end if
	rs.close
  response.write "<tr><td colspan='2' align='right'> <a onClick='history.go(0)'>【刷新页面】</a><a style='cursor:hand'  onclick='window.external.AddFavorite(location.href,document.title);' >【加入收藏】</a><A href='javascript:window.print();'>【打印此文】</A> <a onClick='window.self.close()'>【关闭窗口】</a></td></tr>"
  response.write"</td></tr></table>"
  set rs=nothing
end function
%>
<!--#include file="Foot.asp"-->