<!--#include file="inc_const.asp"-->
<%Response.CacheControl = "Private"
response.expires=0
Set Conn=Server.CreateObject("ADODB.Connection")
conn.open Application( ConstStr & "_connstr")
votename=request("name")
set rs=conn.execute("select * from vote where votename='"&votename&"' order by votenum desc,id")
if rs.eof or rs.bof then
  call echoerr("你要查看的投票事件不存在！","tpxt.asp")
  response.end
elseif rs("begin_time")=rs("end_flag") then
  call echoerr("你要查看的投票事件在没有结束前不允许查看结果！","tpxt.asp")
  response.end
else
  if rs("exp_num")<10 then
    set rs1=conn.execute("select count(*) as count_num from user where DATEDIFF('s',log_time,'"&rs("begin_time")&"')>0 and user_level>"&rs("exp_num"))
  else
    set rs1=conn.execute("select count(*) as count_num from user where DATEDIFF('s',log_time,'"&rs("begin_time")&"')>0 and exp_num>"&rs("exp_num"))
  end if
  voted_user=rs("voted_user")
  end_time=rs("begin_time")%>
<META content="text/html; charset=gb2312" http-equiv=content-type>
<link rel="stylesheet" type="text/css" href="chat.css">
<style>p{margin-left:10px;margin-right:20px;margin-top:5px;margin-bottom:0px;text-align:left}</style>
<body  style="background-color:EAF2FF;color:112233;scrollbar-Base-Color: #b0d8ff;SCROLLBAR-DARKSHADOW-COLOR:#b0d8ff;SCROLLBAR-arrow-COLOR:#336699;SCROLLBAR-TRACK-COLOR: EAF2FF;SCROLLBAR-3DLIGHT-COLOR: #b0d8ff;SCROLLBAR-SHADOW-COLOR: #336699;SCROLLBAR-HIGHLIGHT-COLOR: #b0d8ff;" leftmargin=3 topmargin=3 style="color:green">
  <table height=100% width=100% ><script src="showad.asp?id=1"></script><tr><td align=center valign=center>
  <table align=center width=80% cellspacing=0 cellpadding=0 border=1 BORDERCOLORLIGHT=#000000 BORDERCOLORDARK=#ffffff>
  <tr><td colspan=3 class=navy2>〖<%=votename%>〗投票结果</td></tr>
  <tr><td colspan=3>开始时间:<font color="#0000cc"><%=rs("begin_time")%></font> 投票资格:<font color="#0000cc"><%=rs1("count_num")%></font>人 已投票:<font color="#0000cc"><%=rs("votenum")%></font>人</td></tr>
  <tr><td nowrap class=navy1>序号<td nowrap class=navy1>候选内容<td nowrap class=navy1>得票
  <%i=1
  rs.movenext
  do while not rs.eof%>
    <tr><td nowrap><%=i%><td nowrap><%=rs("voteoptions")%><td nowrap><%=rs("votenum")%>
    <%rs.movenext
    i=i+1
  loop%>
  <tr><td colspan=3 ><p></P><p>投票事件停止于〖<font color="#0000cc"><%=end_time%></font>〗<br>参加投票人员：<font color="#0000cc"><%=voted_user%></font></p><p></p>
</table><br>[<a href='javascript:history.go(-1)'>后退</a>]</td></tr></table></form>
</body></html>
<%end if%><%rs.close
set rs=nothing
rs1.close
set rs1=nothing
conn.close
set conn=nothing%>




