| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 629 人关注过本帖
标题:怎样限制同一ip 30分钟之内不准注册呢?
只看楼主 加入收藏
wayker
Rank: 1
等 级:新手上路
帖 子:2
专家分:0
注 册:2007-3-15
收藏
 问题点数:0 回复次数:4 
怎样限制同一ip 30分钟之内不准注册呢?

<!-- #include file="conn.asp" -->
<%
Dim RS,RS1,RS2,RS3,RS4,RS5,RS6,RS7,Rsmax,RsEmail,SqlStr

Dim NewAccount,UserPass,UserChPass,UserEmail,zhpass

Dim TempString1,TempString2,dbname

Dim sGetCode
dim i
%>

<HTML>

<HEAD>
<TITLE>征途私服</TITLE>
<META http-equiv="Content-Type" content="text/html; charset=gb2312">
<LINK rel="stylesheet" href="gamemembers.css" type="text/css">
%>

<HTML>

<HEAD>
<TITLE></TITLE>
<META http-equiv="Content-Type" content="text/html; charset=gb2312">
<LINK rel="stylesheet" href="gamemembers.css" type="text/css">

<%

If Request.Form("act")="create" Then
UserEmail = checkStr(Request.Form("email_E"))
UserPass = checkStr(Request.Form("pwd_P"))
sGetCode = checkStr(Trim(Request("CheckCode")))
zhpass=checkStr(Trim(Request("idnum")))
If cstr(Session("GetCode"))<>sGetCode or cstr(Session("GetCode"))="" Then
TempString1="您输入的验证码和系统产生的不一致,请重新输入!"
TempString2="<BR><BR><BR><BR><FONT color=#0000FF>3秒后自动返回...</FONT>"
Response.Write("<META http-equiv=refresh content='3; url=create.asp'>")
else
MySQLConn.Open cnnString
Set RsEmail = MySQLConn.Execute("Select * From ACCSTORE0000 Where ACCOUNT='" & UserEmail & "'")
if not (RsEmail.bof and RsEmail.eof) then
TempString1="您填写的帐号已存在,请重新注册!"
TempString2="<BR><BR><BR><BR><FONT color=#0000FF>3秒后自动返回...</FONT>"
Response.Write("<META http-equiv=refresh content='3; url=create.asp'>")
else
if disan="1"then
Set RS = MySQLConn.Execute("Insert Into ACCSTORE0000(ACCOUNT,PASSWD,STATE,TYPE) Values ('" & UserEmail & "','" & UserPass & "','0','0')")
set RsEmail=nothing
Set RsEmail = MySQLConn.Execute("Select * From ACCSTORE0000 Where ACCOUNT='" & UserEmail & "'")
Set RS = MySQLConn.Execute("Insert Into POINTBONUS0000(UID,ACCOUNT,POINT,HADFILLED) Values ('" & RsEmail("UID") & "','" & UserEmail & "','1','1')")
else
Set RS = MySQLConn.Execute("Insert Into ACCSTORE0000(ACCOUNT,PASSWD,STATE,TYPE) Values ('" & UserEmail & "','" & UserPass & "','0','0')")
end if
set RS=nothing
set MySQLConn=nothing
TempString1="帐号注册成功!"
TempString2="<BR><BR><BR><BR><A href='index.asp'>返回首页</a>"
End If
End If

ElseIf Request.Form("act")="change" Then
UserEmail = checkStr(Request.Form("email_E"))
UserPass = checkStr(Request.Form("realname"))
UserChPass = checkStr(Request.Form("pwd_P"))
sGetCode = checkStr(Trim(Request("CheckCode")))

If cstr(Session("GetCode"))<>sGetCode or cstr(Session("GetCode"))="" Then
TempString1="您输入的验证码和系统产生的不一致,请重新输入!"
TempString2="<BR><BR><BR><BR><FONT color=#0000FF>5秒后自动返回...</FONT>"
Response.Write("<META http-equiv=refresh content='5; url=change.asp'>")
Else
MySQLConn.Open cnnString
'Set MySQLConn = Server.CreateObject("ADODB.Connection")
Set RsEmail = MySQLConn.Execute("Select ACCOUNT,PASSWD From ACCSTORE0000 Where ACCOUNT='" & UserEmail & "'")

If RsEmail.EOF Then
TempString1="您输入的帐号不存在!"
TempString2="<BR><BR><BR><BR><FONT color=#0000FF>5秒后自动返回...</FONT>"
Response.Write("<META http-equiv=refresh content='5; url=change.asp'>")

ElseIf UserPass <> RsEmail("PASSWD") Then
TempString1="旧密码错误,您不能修改密码!"
TempString2="<BR><BR><BR><BR><FONT color=#0000FF>5秒后自动返回...</FONT>"
Response.Write("<META http-equiv=refresh content='5; url=change.asp'>")

Else
Set Rs = MySQLConn.Execute("UpDate ACCSTORE0000 Set PASSWD='" & UserChPass & "' Where ACCOUNT='" & UserEmail & "'")
TempString1="密码修改成功!"
TempString2="<BR><BR><BR><BR><FONT color=#0000FF>5秒后自动返回...</FONT>"
Response.Write("<META http-equiv=refresh content='5; url=change.asp'>")
set RS=nothing
set MySQLConn=nothing
End If
End If
End If
%>

</HEAD>

<BODY bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">

<TABLE cellSpacing="0" cellPadding="0" width="100%" border="0">
<TBODY>
<TR>
<TD align='left' width='100%' background='registe/top_bg.jpg' height='157'><IMG src='registe/top1.jpg' alt='征途私服' width='1058' height='192'></TD>
</TR>
</TBODY>
</TABLE>
<TABLE cellSpacing="0" cellPadding="0" width="100%" border="0">
<TBODY>
<TR>
<TD vAlign="top" width="27" background="registe/kuang-bj2.jpg"><IMG height="44" src="registe/kuang-bj2.jpg" width="27"></TD>
<TD vAlign="top" bgColor="#fffbe7" colSpan="2"><TABLE cellSpacing="0" cellPadding="0" border="0">
<TBODY>
<TR>
<TD><img height="41" src="registe/register_title_03.gif" width="838" vspace="20"></TD>
</TR>
<TR>
<TD align="middle"></TD>
</TR>
<TR>
<TD align="middle"><TABLE cellSpacing="0" cellPadding="0" width="80%" border="0">
<TBODY>
<TR align="middle">
<TD><A href="step_1.shtml"></A></TD>
<TD><IMG height="48" src="registe/btn_edit_09.gif" width="165"></TD>
<TD><IMG height="24" src="registe/btn_arrow_14.gif" width="51"></TD>
<TD><IMG height="48" src="registe/btn_succ_11.gif" width="165"></TD>
</TR>
<TR align="middle">
<TD colSpan="4"></TD>
</TR>
<TR align="middle">
<TD colSpan="4"><TABLE cellSpacing="0" cellPadding="0" width="80%" align="center" border="0">
<TBODY>
<TR>
<TD vAlign=middle align=center><FONT color=#FF0000><%=TempString1%></FONT><%=TempString2%></TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
<TR align="middle">
<TD colSpan="4"></TD>
</TR>
<TR align="middle">
<TD colSpan="4"></TD>
</TR>
<TR align="middle">
<TD colSpan="4"></TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
<TR>
<TD></TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
<TR>
<TD vAlign="top" height="16"><IMG height="44" src="registe/zuoxiajiao1.jpg" width="27"></TD>
<TD vAlign="top" background="registe/kuang-bj3.jpg" bgColor="#fffbe7"><IMG height="44" src="registe/zuoxiajiao2.jpg" width="14"></TD>
<TD vAlign="top" background="registe/kuang-bj3.jpg" bgColor="#fffbe7"></TD>
</TR>
</TBODY>
</TABLE>

</BODY>

</HTMP>

在这段代码里加上什么内容就可以限制30分钟同一ip不能注册了?
高手们帮帮忙

搜索更多相关主题的帖子: 注册 
2007-10-15 14:54
niuniu2009kk
Rank: 1
等 级:新手上路
帖 子:33
专家分:0
注 册:2007-10-15
收藏
得分:0 
我也看不出来,期待高手的驾临……

太懒,今天就说一句话,好了,我说完了……
2007-10-15 15:05
Palepast
Rank: 1
等 级:新手上路
帖 子:31
专家分:0
注 册:2007-10-15
收藏
得分:0 
不懂^
2007-10-15 15:24
jinli01001
Rank: 1
等 级:新手上路
帖 子:14
专家分:0
注 册:2007-8-24
收藏
得分:0 
都等这吧
2007-10-16 01:19
wayker
Rank: 1
等 级:新手上路
帖 子:2
专家分:0
注 册:2007-3-15
收藏
得分:0 

顶起 有没有高手来帮忙呢

2007-10-16 02:12
快速回复:怎样限制同一ip 30分钟之内不准注册呢?
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.026902 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved