<%@ Language=VBScript %>
<!--#include virtual="/inc-freehost-function/FreeHostFunction.asp"-->
<!--#include virtual="/inc-freehost-function/FreeHostFunctionMain.asp"-->
<%
id=session("DNSAUID")
If session("DNSAUID")="" Then
	ef=True
	ec="授权非法，请您先登陆。"
ElseIf not IsNumeric(id)  Then
	ef=True
	ec="ID应该是数字！"
end if

if not ef then
Set conn=Server.CreateObject("ADODB.Connection")
	conn.Open Application("FreeHostDBlink")
	Set dsdom = Server.CreateObject("ADODB.Recordset")	
		Sql="Select * from FreeHost.FreeHost_Product_Domain where id='"&id&"'"
			if Instr(1,sql, ";", 1)>0 or Instr(1,sql, "--", 1)>0 then
outcon="非法字符！"
Response.End
end if
	dsdom.Open Sql,conn,1,3
if dsdom.Eof then
	ef=True
	ec="不存在的域名！"
end if
end if

if not ef Then
If dsdom("api7select")<>2 Then
	ef=True
	ec="1API的域名才能用这个功能！"
end if
end If

if not ef Then
Dim enc
Enddomaintypeid=GetDomaintype(dsdom("Domain"))
uname1=dsdom("uname1")
uname2=dsdom("uname2")
uname3=dsdom("uname3")
uname4=dsdom("uname4")
rname1=dsdom("rname1")
rname2=dsdom("rname2")
ust=dsdom("ust")
uprov=dsdom("uprov")
ucity1=dsdom("ucity1")
ucity2=dsdom("ucity2")
uaddr1=dsdom("uaddr1")
uaddr2=dsdom("uaddr2")
location=dsdom("location")
uzip=dsdom("uzip")
utelc=dsdom("utelc")
utela=dsdom("utela")
uteln=dsdom("uteln")
utele=dsdom("utele")
ufaxc=dsdom("ufaxc")
ufaxa=dsdom("ufaxa")
ufaxn=dsdom("ufaxn")
ufaxe=dsdom("ufaxe")
uemail=dsdom("uemail")
aname1=dsdom("aname1")
aname2=dsdom("aname2")
atelc=dsdom("atelc")
atela=dsdom("atela")
ateln=dsdom("ateln")
atele=dsdom("atele")
afaxc=dsdom("afaxc")
afaxa=dsdom("afaxa")
afaxn=dsdom("afaxn")
afaxe=dsdom("afaxe")
aemail=dsdom("aemail")
dns1=dsdom("dns1")
dns2=dsdom("dns2")
period=dsdom("years")
end if


If Not ef Then%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>Mydns</title>
<style type="text/css">
<!--
.tableborder {
	BORDER-RIGHT: #345487 1px solid; PADDING-RIGHT: 0px; BORDER-TOP: #345487 1px solid; PADDING-LEFT: 0px; PADDING-BOTTOM: 0px; MARGIN: 0px; BORDER-LEFT: #345487 1px solid; WIDTH: 98%; PADDING-TOP: 0px; BORDER-BOTTOM: #345487 1px solid; BACKGROUND-COLOR: #fff
}
p9,body,td,p,br {  font-size: 9pt}
A:visited {	TEXT-DECORATION: none;color: #666666;}
A:hover { TEXT-DECORATION: none;color: #666666;}
A:link {
	TEXT-DECORATION: none;
	color: #666666;
}
.inp {height: 20px;width:100px}
.inp2 {height: 20px;width:50px}
-->
</style>
</head>
<BODY text=#000000 bgColor=#FFFFFF leftmargin="0" topmargin="0" bottommargin="0" rightmargin="0" marginwidth="0" marginheight="0"><br>
<br>
<br>
<br>

<form method="POST" action="modidns-sub.asp" name="domainform">
              <table border="0" cellspacing="0" cellpadding="1" bgcolor="#993300" align="center" width="630">
                <tr>
                  <td><table border="0" cellspacing="1" cellpadding="3" width="630">

                     
                      <tr>
                        <td bgcolor="#FF6600" width="30%"><font color="#FFFFFF">修改DNS</td>
                        <td bgcolor="#FFFFFF">　</td>
                      </tr>
                      <tr bgcolor="#FFCC66">
                        <td width="30%" bgcolor="#FFCC66"> 当前DNS： <br>            </td>
                        <td bgcolor="#FFFFFF">
                          　<%if isnull(dsdom("dns1")) then%>ns1.ispapi.net;ns2.ispapi.net;ns3.ispapi.net<%else%><%=dsdom("dns1")%>;<%=dsdom("dns2")%><%end if%>
</tr>
                      <tr>
                        <td width="30%" bgcolor="#FFCC66"> 修改为：<br>            </td>
                        <td bgcolor="#FFFFFF">
                          　</td>
                      </tr>
                      <tr>
                        <td width="30%" bgcolor="#FFCC66">已注册的DNS1：</td>
                        <td bgcolor="#FFFFFF">
                          <input name="dns1" id="dns1" value="<%=dsdom("dns1")%>" size="40" maxlength="49">
                        </td>
                      </tr>
                      <tr>
                        <td bgcolor="#FFCC66">已注册的DNS2：</td>
                        <td bgcolor="#FFFFFF"><input name="dns2" id="dns2" value="<%=dsdom("dns2")%>" size="40" maxlength="49"></td>
                      </tr>
                      <tr>
                        <td width="30%" bgcolor="#FFCC66">已注册的DNS3：</td>
                        <td bgcolor="#FFFFFF">
                          <input name="dns3" id="dns3" value="<%=dsdom("dns3")%>" size="40" maxlength="49">
                          (可以不填写)</td>
                      </tr>

                        <td colspan="2" bgcolor="#FFFFFF" align="center">                          <br>
                          <br>
<input type="submit" name="B1" value="保存">
<br>
                        <br></td>
                      </tr>
                  </table></td>
                </tr>
  </table>
              <br>
              <br>
              <br>
</form>
</body>
</html>
<%
end if
if ef then
Response.Redirect "e.asp?e="&ec
end if%>