<%@ Language=VBScript %> <% If session("username")="" Then ef=True ec="授权非法,有可能是超时造成的。" If session("HOSTAUID")<>"" Then ec="主机面板中不能操作用户区的内容,请您先登陆用户区。" If session("EmailAUID")<>"" Then ec="邮箱面板中不能操作用户区的内容,请您先登陆用户区。" If session("SQLAUID")<>"" Then ec="数据库面板中不能操作用户区的内容,请您先登陆用户区。" ElseIf Request("sqlname")<>"" and (RegExpTest("[^A-Za-z0-9]",Request("sqlname")) or Instr(1, Request("sqlname"), "'", 1)>0 or Instr(1, Request("sqlname"), "-", 1)>0 or Instr(1, Request("sqlname"), " ", 1)>0 or Instr(1, Request("sqlname"), "&", 1)>0 or Instr(1, Request("sqlname"), ".", 1)>0 or Instr(1, Request("sqlname"), "_", 1)>0) Then ef=True ec="数据库用户名中有非法字符!" ElseIf Request("ftpname")<>"" and (RegExpTest("[^A-Za-z0-9]",Request("ftpname")) or Instr(1, Request("ftpname"), "'", 1)>0 or Instr(1, Request("ftpname"), "-", 1)>0 or Instr(1, Request("ftpname"), " ", 1)>0 or Instr(1, Request("ftpname"), "&", 1)>0 or Instr(1, Request("ftpname"), ".", 1)>0 or Instr(1, Request("ftpname"), "_", 1)>0) Then ef=True ec="FTP用户名中有非法字符!" end If if not ef Then If trim(replace(Request("hostname"),"http://",""))<>"" then set ComX=server.CreateObject("freehost_com_7i24.FreehostM") hostname=trim(replace(Request("hostname"),"http://","")) if hostname<>"" then hostname=ComX.idntoac_7i24_com(cstr(hostname)) hostnamecheck=replace(hostname,".","") hostnamecheck=replace(hostnamecheck,"xn--","") If RegExpTest("[^A-Za-z0-9--]",hostnamecheck) Then ef=True ec="请输入合法的域名!" end If end if end if if not ef then %> SQL数据库管理

<%Set conn=Server.CreateObject("ADODB.Connection") conn.Open Application("FreeHostDBlink") byhost=0 if Request("ftpname")<>"" or trim(replace(Request("hostname"),"http://",""))<>"" then Set dsph = Server.CreateObject("ADODB.Recordset") if Request("ftpname")<>"" then Sql="Select * from FreeHost.FreeHost_Product_Host where username='"&session("username")&"' and Hosttype<>'子目录绑定' and ftpname like '%"&Request("ftpname")&"%'" if Request("hostname")<>"" then Sql="Select * from FreeHost.FreeHost_Product_Host where username='"&session("username")&"' and Hosttype<>'子目录绑定' and hostname like '%"&ComX.idntoac_7i24_com(cstr(hostname))&"%'" if Instr(1,sql, ";", 1)>0 or Instr(1,replace(sql,"xn--",""), "--", 1)>0 then Response.Write "非法字符!" Response.End end If 'Response.write sql dsph.Open Sql,conn,1,1 if Not dsph.Eof Then byhost=dsph("id") End if End If Set dsphSql = Server.CreateObject("ADODB.Recordset") Sql="Select * from FreeHost.FreeHost_Product_Sql where username='"&session("username")&"' order by endtime desc" if Request("sqlname")<>"" then Sql="Select * from FreeHost.FreeHost_Product_Sql where username='"&session("username")&"' and sqlname like '%"&Request("sqlname")&"%'" If byhost>0 then Sql="Select * from FreeHost.FreeHost_Product_Sql where username='"&session("username")&"' and byhost='"&byhost&"'" if Instr(1,sql, ";", 1)>0 or Instr(1,sql, "--", 1)>0 then Response.Write "非法字符!" Response.End end if dsphSql.PageSize = 25 dsphSql.Open Sql,conn,1,1 if dsphSql.Eof then%> 没有开通的数据库产品. <%else%> <% if Request.ServerVariables("QUERY_STRING")<>"" then ask=Split(Request.ServerVariables("QUERY_STRING"), chr(38)&"pn") else ask=Split("freehost=1", "") ask(0)="freehost=lsoft" end if pn=1 if Request.QueryString ("pn")<>"" then pn=Request.QueryString ("pn") If dsphSql.RecordCount <> 0 Then dsphSql.AbsolutePage = CLng(pn) if clng(pn)<=10 then begini=1 if dsphSql.PageCount<=10 then endini=dsphSql.PageCount else endini=10 end if end if %> <%if clng(pn)<=10 then%>最新 <%for i=begini to endini if clng(pn)=i then%>[<%=i%>]<%else%>[<%=i%>]<%end if%> <%next%> <%else%> 最新[1]--[10]  现在是第[<%=pn%>]页  共<%=dsphSql.PageCount%>页 <%end if%><%If Clng(pn)>1 Then%>上一页<%End If%>|<%If Clng(pn)下一页 <%End If%> <% For N=1 To dsphSql.PageSize If dsphSql.RecordCount=0 Then Exit For %> <% Sqltype=dsphSql("Sqltype") Set ori_Sql_name = Server.CreateObject("ADODB.Recordset") Sql="Select * from FreeHost.FreeHost_SqlProductlist where Sqltype='"&dsphSql("Sqltype")&"'" ori_Sql_name.Open Sql,conn,1,1 if not ori_Sql_name.eof then Set newname_Sql = Server.CreateObject("ADODB.Recordset") Sql="Select * from FreeHost.FreeHost_SqlProductlist_AGN where agent1='"&session("agentname")&"' and id='"&ori_Sql_name("id")&"'" newname_Sql.Open Sql,conn,1,1 if not newname_Sql.eof then Sqltype=newname_Sql("Sqltype") end if end if %> <% If clng(pn)=dsphSql.PageCount Then I = dsphSql.RecordCount - (dsphSql.PageCount-1) * dsphSql.PageSize If N=I Then Exit For End If dsphSql.movenext Next%>
产品类型 数据库名 所属父产品 IP 地址 开通日期 到期日期 操作 操作 状态 操作
<%=Sqltype%> <%=dsphSql("sqlname")%> <% Set dsph = Server.CreateObject("ADODB.Recordset") Sql="Select * from FreeHost.FreeHost_Product_Host where id='"&dsphSql("byhost")&"' and username='"&session("username")&"'" dsph.Open Sql,conn,1,1 if not dsph.Eof then nohost=false%> &go=a">虚拟主机(<%=dsph("ftpname")%>) <%else%> 无 <%end if%> <% Set dsserver = Server.CreateObject("ADODB.Recordset") Sql="Select * from FreeHost.FreeHost_Serversqllist where id='"&dsphSql ("ServerlistID")&"'" dsserver.Open Sql,conn,1,1 %><%=dsserver("ip")%><%dsserver.close%> <%=formatdatetime(dsphSql("starttime"),1)%> <%=formatdatetime(dsphSql("endtime"),1)%> &go=c">延期 &go=d">升级 <%if dsphSql("endtime")>NOW then%> <%if dsphSql("istest")="y" then%> 试用<%else%> <%=dsphSql("status")%> <%end if%> <%else%> 过期 <%if dsphSql("status")="暂停" then%>
暂停 <%end if%> <%end if%>
&go=a">管理
<%dsphSql.close set dsphSql=nothing end if %>


查找数据库:

 数据库名: 或FTP用户名: 或域名

<%end if if ef then Response.Redirect "e.asp?e="&ec end if%>