ͶƱ ?ֻ?Դ??
<%
function getIP()
getIP = Request.ServerVariables("HTTP_X_FORWARDED_FOR")
If getIP = "" Then getIP = Request.ServerVariables("REMOTE_ADDR")
end function
if Request.Cookies("mycookie")("userip")<>"" then
Response.Write "<script>alert('一个IP地址只能投一次票,谢谢您的手机参与!');history.go(-1);</script>"
response.End()
else
Response.Cookies("mycookie")("userip")=getIP()
Response.Cookies("mycookie").Expires=date+
end if
%>
把以上代码放在你投票页的源码正规马来溯源码前面就行了
高手进,ASP 根据IP判断投票全代码
我弄的,一个IP一天只能投票一次
。投票改.,手机混沌算盘指标源码访问:flycentrury。com。源码Saas系统框源码cn
如果选手机,投票你选择的手机价位是:
……
你可以试验一下
以下是我按你的数据库改的源码
<%
function ips()
dim id
id=Request.ServerVariables("REMOTE_HOST")
if Request.ServerVariables("HTTP_X_FORWARDED_FOR")<>"" then
id=Request.ServerVariables("HTTP_X_FORWARDED_FOR")
end if
ips=id
end function
ip=ips()
set rc=server.CreateObject("adodb.recordset")
sql="select tptime,ip from ip where ip='"&ip&"' and tptime=#"&date()&"#"
rc.open sql,conn,1,1
aa=rc.recordcount
rc.close
set rc=nothing
if aa>0 then
Response.Write "<script>alert('您今天已经投过票啦!');this.location.href='javascript:window.close()';</SCRIPT>"
else
sql="update Vote set ps=ps+1 where id="&pid
conn.execute(sql)
conn.close
set conn=nothing
Response.Write "<script>alert('谢谢您的源码关注,投票成功!投票');this.location.href='javascript:window.close()';</SCRIPT>"
手机end if
手机%>
手机2024-12-29 00:04
2024-12-28 23:38
2024-12-28 23:22
2024-12-28 22:36
2024-12-28 21:35