|
- <%@ Language=VBScript %>
- <%
- if Application("domain_database")="" then
- datafile="coc/dom.asp"
- connstr="Provider=Microsoft.Jet.OLEDB.4.0;"&_
- "Data Source="& Server.MapPath(datafile)
- set conn=Server.CreateObject("ADODB.CONNECTION")
- Set rs=Server.CreateObject("ADODB.RecordSet")
- conn.Open connstr
- Application("domain_database")=connstr
- domain_info=""
- rs.Open ("select [domain],[ad],[height],[width],[url] from [domain] order by [top] desc"),conn,1,1
- do while not (rs.bof or rs.eof)
- domain_info=domain_info&rs(0)&"|"&rs(1)&"|"&rs(2)&"|"&rs(3)&"|"&rs(4)&"|"
- rs.movenext
- loop
- Application("domain_online")=0
- Application("domain_info")=domain_info
- rs.close
- rs.Open ("select [filter],[sift] from [system]"),conn,1,1
- Application("domain_filter")=rs(0)
- Application("domain_sift")=rs(1)
- rs.Close
- set rs=nothing
- conn.Close
- set conn=nothing
- end if
- sURL=Request.ServerVariables("HTTP_HOST")
- if InStr(sURL,"=")<>0 or InStr(sURL,"`")<>0 or InStr(sURL,"'")<>0 or InStr(sURL," ")<>0 or InStr(sURL," ")<>0 or InStr(sURL,"'")<>0 or InStr(sURL,chr(34))<>0 or InStr(sURL,"")<>0 or InStr(sURL,",")<>0 or InStr(sURL,"<")<>0 or InStr(sURL,">")<>0 then
- Response.Status= "404 no found"
- Response.End
- end if
- first_name=split(sURL,".")
- if ubound(first_name)>2 then
- Response.Status= "404 no found"
- Response.End
- end if
- user=first_name(0)
- seldomain=first_name(1)&"."&first_name(2)
- if user="reg" then Response.Redirect "http://xxx.cn/reg/index.asp"
- '这里的这个指向是你给这个程序设置的域名的路径
- geturl=False
- msg=Application("domain_info")
- msg=split(msg,"|")
- for i=lbound(msg) to ubound(msg)-1 step 5
- if msg(i)=seldomain then
- geturl=True
- ad=msg(i+1)
- height=msg(i+2)
- width=msg(i+3)
- adurl=msg(i+4)
- exit for
- end if
复制代码 访问提示:
Microsoft VBScript 运行时错误 错误 '800a0009'
下标越界: '[number: 2]'
/index.asp,行 41
什么问题呢?球高手解答。。。 |
|