⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vote1.asp

📁 完美政府版,正版网站解决方案
💻 ASP
字号:
<% Response.Buffer=True %>
<!--#include file="conn.asp"-->
<!--#include file="config.asp"-->
<!--#include file="char.inc"-->
<%
if request.QueryString("stype")="" then
	if Request.ServerVariables("REMOTE_ADDR")=request.cookies(Forcast_SN)("IPAddress") then
		response.write"<SCRIPT language=JavaScript>alert('感谢您的支持,您已经投过票了,请勿重复投票,谢谢!');"
		response.write"javascript:window.close();</SCRIPT>"
	else
		options=request.form("options")
		response.cookies(Forcast_SN)("IPAddress")=Request.ServerVariables("REMOTE_ADDR") 
		set rs=server.createobject("adodb.recordset")
		sql="update "& db_Vote_Table &" set answer"&options&"=answer"&options&"+1 where IsChecked=1"
		rs.open sql,conn,1,3
		set rs=nothing
	end if
end if
%>

<head> 
<title><%=redcaff%>投票结果&#23436;&#32654;&#35774;&#35745;&#32593;&#32476;&#31185;&#25216;&#26377;&#38480;&#20844;&#21496;&#32;&#23436;&#32654;&#25919;&#24220;&#32593;&#31449;&#31649;&#29702;&#31995;&#32479;&#32;&#104;&#116;&#116;&#112;&#58;&#47;&#47;&#119;&#119;&#119;&#46;&#119;&#109;&#103;&#111;&#118;&#46;&#99;&#110;</title>
<LINK href=site.css rel=stylesheet>
</head>
<body topmargin="0">
<!--#include file=top.asp-->
<div align="center"></center> 
<table width="1002" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
	<tr valign="top"> 
		<td width="180" bordercolor="#FDFCF8"  bgcolor="#FDFCF8" style="border-left: 1px solid #cccccc ; border-top: 1px solid #cccccc ; border-bottom: 1px solid #cccccc ; border-right: 1px solid #cccccc ">
<!--#include file="WmCms_Linterflow.asp"-->
</td>

		<td width="6"></td>
		<td width="810" style="border-left: 1px solid #cccccc ; border-top: 0px solid #cccccc ; border-bottom: 1px solid #cccccc ; border-right: 1px solid #cccccc ">

	<table border="0" cellpadding="0" cellspacing="0" width="500" height="48" bordercolor=<%=border%> style="border-collapse: collapse">
    		<br><br><br><br><%
		total=0
		set rs=server.createobject("adodb.recordset")
		sql="select * from "& db_Vote_Table &" where IsChecked=1"
		rs.open sql,conn,1,1
		%>
		<tr align="center"> 
			<td height="24" colspan="4" valign="top"><font color="#000000">『</font><font color="#000073"><%=rs("Title")%></font><font color="#000000">』投票结果</font><br>
			</td>
		</tr>
		<tr>
			<td height="24" valign="top" colspan="4"><font color="#000000">=============================================================================</font><br>
			</td>
		</tr>
		<tr>
			<td width="22%" valign="top">序号</td>
			<td valign="top">百比分</td>
			<td colspan="2" align="center" valign="top">人数</td>
		</tr>
		<%
		for i=1 to 8
			if rs("Select"&i)<>"" then
				total=total+rs("answer"&i)
			end if
		next
		for i=1 to 8
			if rs("Select"&i)<>"" then
				if total=0 then
					answer=0
				else
					answer=(rs("answer"&i)/total)*100
				end if%>
		<tr>
			<td valign="top"><%=i%>.<%=rs("select"&i)%>:</td>
			<td width="56%" valign="top"><img src=images/RSCount.gif width=<%=int(answer*2)%> height=8></td>
			<td width="12%" valign="top"><%=round(answer,3)%>%</td>
			<td width="10%" valign="top"><%=rs("answer"&i)%>人</td>
			<%end if
		next%>
		</tr>
		<tr>
			<td colspan="4"> 共有【<%=total%>】人参加投票<br>=============================================================================</font></center></td>
		</tr>
	</table>

</div>
<BR>
<div align="center">非常感谢您的支持您可以如下操作:<BR><BR>【<a href="guestbook.asp" target="_blank">留下建议</a>】【<a href="javascript:window.close()">关闭窗口</a>】<br><br><br><br>
	<% rs.close     
	set rs=nothing     
	conn.close     
	set conn=nothing %>
</div>
</td></tr></table>
</body>
<!--#include file=Bottom.asp-->

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -