<%@ Language=VBScript %>
<!--#include virtual="/inc-freehost-function/FreeHostFunction.asp"-->
<!--#include virtual="/inc-freehost-function/FreeHostFunctionMain.asp"-->
<%
server.ScriptTimeout =2400
If session("admau")="" Then
	ef=True
	ec="授权非法，有可能是超时造成的。"
ElseIf Request.Form ("Hosttype")=""  or Instr(Request.Form ("Hosttype"), "'")>1  Then
	ef=True
	ec="产品名没填！"
ElseIf Request.Form ("ServerlistID")="" And Request.Form ("isagentpd")="" Then
	ef=True
	ec="所在服务器没填！"

ElseIf Request.Form ("isagentpd")="1" And not IsNumeric(Request.Form ("Agnidc"))  Then
	ef=True
	ec="上级代理服务器ID应该是数字！"
ElseIf Request.Form ("isagentpd")="1" And not IsNumeric(Request.Form ("Agnproductid"))  Then
	ef=True
	ec="上级代理产品ID应该是数字！"
ElseIf Request.Form ("isagentpd")="1" And Request.Form ("HostApiName")=""  Then
	ef=True
	ec="上级代理API域名不能为空！"
ElseIf Request.Form ("isagentpd")="1" And Request.Form ("Hostcpdomain")=""  Then
	ef=True
	ec="上级代理面板域名不能为空！"
ElseIf Request.Form ("isagentpd")="1" And Request.Form ("Agnuserid")=""  Then
	ef=True
	ec="上级代理名不能为空！"
ElseIf Request.Form ("isagentpd")="1" And Request.Form ("Domain_Agent_nonemd5_6")=""  Then
	ef=True
	ec="上级代理密码不能为空！"

ElseIf Request.Form ("ostype")="windows" And Request.Form ("MaxConnections")="" Then
	ef=True
	ec="IIS连接数没填！"
ElseIf not IsNumeric(Request.Form ("MaxConnections"))  Then
	ef=True
	ec="IIS连接数应该是数字！"
ElseIf Request.Form ("ostype")="windows" And Request.Form ("MaxBandwidth")="" Then
	ef=True
	ec="带宽限制必须设置！"
ElseIf not IsNumeric(Request.Form ("MaxBandwidth"))  Then
	ef=True
	ec="带宽限制应该是数字！"
ElseIf Request.Form ("spacelimt")="" Then
	ef=True
	ec="空间大小限制没填！"
ElseIf Request.Form ("usermoney")="" Then
	ef=True
	ec="金额没填！"
ElseIf not IsNumeric(Request.Form ("usermoney"))  Then
	ef=True
	ec="金额应该是数字！"

ElseIf Request.Form ("PAY_Month")="" Then
	ef=True
	ec="月付没填！"
ElseIf not IsNumeric(Request.Form ("PAY_Month"))  Then
	ef=True
	ec="月付应该是数字！"
ElseIf Request.Form ("PAY_Season")="" Then
	ef=True
	ec="季付没填！"
ElseIf not IsNumeric(Request.Form ("PAY_Season"))  Then
	ef=True
	ec="季付应该是数字！"
ElseIf Request.Form ("PAY_halfyear")="" Then
	ef=True
	ec="半年付没填！"
ElseIf not IsNumeric(Request.Form ("PAY_halfyear"))  Then
	ef=True
	ec="半年付应该是数字！"
ElseIf Request.Form ("PAY_Nextyear")="" Then
	ef=True
	ec="续费没填！"
ElseIf not IsNumeric(Request.Form ("PAY_Nextyear"))  Then
	ef=True
	ec="续费应该是数字！"
ElseIf Request.Form ("PAY_2year")="" Then
	ef=True
	ec="二年付费率没填！"
ElseIf not IsNumeric(Request.Form ("PAY_2year"))  Then
	ef=True
	ec="二年付费率应该是数字！"
ElseIf Request.Form ("PAY_3year")="" Then
	ef=True
	ec="三年付费率没填！"
ElseIf not IsNumeric(Request.Form ("PAY_3year"))  Then
	ef=True
	ec="三年付费率应该是数字！"
ElseIf Request.Form ("PAY_4year")="" Then
	ef=True
	ec="四年付费率没填！"
ElseIf not IsNumeric(Request.Form ("PAY_4year"))  Then
	ef=True
	ec="四年付费率应该是数字！"
ElseIf Request.Form ("PAY_5year")="" Then
	ef=True
	ec="五年付费率没填！"
ElseIf not IsNumeric(Request.Form ("PAY_5year"))  Then
	ef=True
	ec="五年付费率应该是数字！"

ElseIf Request.Form ("ostype")="windows" And Request.Form ("html")<>"y" Then
	ef=True
	ec="必须支持html!"
ElseIf Request.Form ("ostype")="windows" And Request.Form("AppPoolnum")="" Then
	ef=True
	ec="请指定共同一个池的用户数,如果您的系统是win 2000,请设为50"
ElseIf Request.Form("isbydomain")="y" and Request.Form("cantest")="y" Then
	ef=True
	ec="送域名的虚拟主机不能设为试用！"
ElseIf len(Request.Form("oridir"))>1 Then
   If Right(Request.Form("oridir"),1)="\" Then
   	ef=True
	ec="预装网站的目录名不能用\结尾，如，应该是类似于d:\test\bbs的格式！"
   End if
elseIf session("cansetpro")="" Then
	ef=True
	ec="您没有此操作的权限。"
end if
if not ef then
Set conn=Server.CreateObject("ADODB.Connection")
	conn.Open Application("FreeHostDBlink")
	Set ds = Server.CreateObject("ADODB.Recordset")	
		Sql="Select * from FreeHost.FreeHost_HostProductlist where Hosttype='"&Request.Form ("Hosttype")&"'"
		ds.Open Sql,conn,1,3
if not ds.Eof and Request.Form ("modify")<>"修改" and Request.Form ("delit")<>"删除" then
	ef=True
	ec="已存在同名的产品！"
end if

if Request.Form ("modify")="修改" and ds.Eof then
	ef=True
	ec="没找到要修改的产品！"
end if

if Request.Form ("delit")="删除" and not ds.Eof then
Set dsph = Server.CreateObject("ADODB.Recordset")	
Sql="Select * from FreeHost.FreeHost_Product_Host where Hosttype='"&Request.Form ("Hosttype")&"'"
	dsph.Open Sql,conn,1,1
if not dsph.Eof then
	ef=True
	ec="此产品已有开通的用户，只能修改，不能删除！"
end if
dsph.close
set dsph=nothing
end if

if not ef then
if Request.Form ("delit")<>"删除" then
if Request.Form ("modify")<>"修改" then ds.addnew
ds("Hosttype")=Request.Form("Hosttype")
ds("usermoney")=Request.Form("usermoney")
ds("ServerlistID")=Request.Form("ServerlistID")
ds("MaxConnections")=Request.Form("MaxConnections")
If Request.Form("MaxConnections")="" Then ds("MaxConnections")=4294967295
ds("spacelimt")=Request.Form("spacelimt")
ds("info")=Request.Form("info")
ds("infomore")=Request.Form("infomore")
ds("AppPoolnum")=Request.Form("AppPoolnum")
If Request.Form("AppPoolnum")="" Then ds("AppPoolnum")=999

ds("html")=Request.Form("html")
ds("asp")=Request.Form("asp")
ds("aspx")=Request.Form("aspx")
ds("php")=Request.Form("php")
ds("cgi")=Request.Form("cgi")
ds("jsp")=Request.Form("jsp")
if Request.Form("isbydomain")="y" then
ds("isbydomain")="y"
ds("Domaintype")=Request.Form("Domaintype")
else
ds("isbydomain")="n"
end if
if Request.Form("cantest")="y" then
ds("cantest")="y"
else
ds("cantest")="n"
end if
if Request.Form("canmonth")="y" then
ds("canmonth")="y"
else
ds("canmonth")="n"
end if

if Request.Form("canseason")="y" then
ds("canseason")="y"
else
ds("canseason")="n"
end if

if Request.Form("canhalfyear")="y" then
ds("canhalfyear")="y"
else
ds("canhalfyear")="n"
end If

if Request.Form("canrecypool")="y" then
ds("canrecypool")="y"
else
ds("canrecypool")="n"
end if

if Request.Form("canchnetver")="y" then
ds("canchnetver")="y"
else
ds("canchnetver")="n"
end if

if Request.Form("notuserar")="y" then
ds("notuserar")="y"
else
ds("notuserar")="n"
end if


if Request.Form("canbyenduser")="y" then
ds("canbyenduser")="y"
else
ds("canbyenduser")="n"
end if
if Request.Form("canbyagnenduser")="y" then
ds("canbyagnenduser")="y"
else
ds("canbyagnenduser")="n"
end if
if Request.Form("canbyagn")="y" then
ds("canbyagn")="y"
else
ds("canbyagn")="n"
end if

if  IsNumeric(Request.Form("orderbyid")) then
ds("orderbyid")=Request.Form("orderbyid")
else
ds("orderbyid")=0
end if

if  IsNumeric(Request.Form("typeid")) then
ds("typeid")=Request.Form("typeid")
else
ds("typeid")=0
end if

if Request.Form("allowupdate")="y" then
ds("allowupdate")="y"
else
ds("allowupdate")="n"
end if

if Request.Form("allowupdatetoother")="y" then
ds("allowupdatetoother")="y"
else
ds("allowupdatetoother")="n"
end if

ds("MaxBandwidth")=Request.Form("MaxBandwidth")
If Request.Form("MaxBandwidth")="" Then ds("MaxBandwidth")=4294967295'IIS 6中的带宽



if Request.Form("allowsub")="y" then
ds("allowsub")="y"
else
ds("allowsub")="n"
end if

if Request.Form("cangetlog")="y" then
ds("cangetlog")="y"
else
ds("cangetlog")="n"
end if

if  IsNumeric(Request.Form("Maxbytes")) then
ds("Maxbytes")=CDbl(Request.Form ("Maxbytes")*1024*1024)
else
ds("Maxbytes")=0
end If

if  IsNumeric(Request.Form("CDNMaxMb")) then
ds("CDNMaxMb")=Request.Form ("CDNMaxMb")
else
ds("CDNMaxMb")=0
end if

if  IsNumeric(Request.Form("MaxCPU")) then
ds("MaxCPU")=CDbl(Request.Form ("MaxCPU")*8640000*5)
else
ds("MaxCPU")=0
end if


if  IsNumeric(Request.Form("subweb")) then
ds("subweb")=Request.Form("subweb")
else
ds("subweb")=0
end if

if  IsNumeric(Request.Form("allowdomain")) then
ds("allowdomain")=Request.Form("allowdomain")
else
ds("allowdomain")=0
end If

if  IsNumeric(Request.Form("CDNpdID")) then
ds("CDNpdID")=Request.Form("CDNpdID")

	Set dsCDN = Server.CreateObject("ADODB.Recordset")	
		Sql="Select * from FreeHost.FreeHost_CDNProductlist order by id asc"
		dsCDN.Open Sql,conn,1,3
		If Not dsCDN.eof Then
		if  IsNumeric(Request.Form("CDNMaxMb")) Then dsCDN("CDNMaxMb")=Request.Form ("CDNMaxMb")
		dsCDN.update
		End if


else
ds("CDNpdID")=0
end if

if Request.Form("canseelog")="y" then
ds("canseelog")="y"
else
ds("canseelog")="n"
end if

if Request.Form("canrar")="y" then
ds("canrar")="y"
else
ds("canrar")="n"
end if

if Request.Form("canback")="y" then
ds("canback")="y"
else
ds("canback")="n"
end if

if Request.Form("cantwodb")=1 then
ds("cantwodb")=1
else
ds("cantwodb")=0
end If

if Request.Form("updatebytypeid")="y" then
ds("updatebytypeid")="y"
else
ds("updatebytypeid")="n"
end if


ds("netver")=Trim(Request.Form("netver"))
if Trim(Request.Form("netver"))="" Then ds("netver")=null

if Request.Form("canupdatespace")="y" and IsNumeric(Request.Form("updatespacemoney")) then
ds("canupdatespace")="y"
ds("updatespacemoney")=Request.Form("updatespacemoney")
else
ds("canupdatespace")="n"
end if

if Request.Form("canupdateiis")="y" and IsNumeric(Request.Form("updateiismoney")) then
ds("canupdateiis")="y"
ds("updateiismoney")=Request.Form("updateiismoney")
else
ds("canupdateiis")="n"
end if

if Request.Form("canupdatebank")="y" and IsNumeric(Request.Form("updatebanksmoney")) then
ds("canupdatebank")="y"
ds("updatebanksmoney")=Request.Form("updatebanksmoney")
else
ds("canupdatebank")="n"
end if

if Request.Form("canupdatebyte")="y" and IsNumeric(Request.Form("updatebytesmoney")) then
ds("canupdatebyte")="y"
ds("updatebytesmoney")=Request.Form("updatebytesmoney")
else
ds("canupdatebyte")="n"
end if

if Request.Form("canupdatecpu")="y" and IsNumeric(Request.Form("updatecpusmoney")) then
ds("canupdatecpu")="y"
ds("updatecpusmoney")=Request.Form("updatecpusmoney")
else
ds("canupdatecpu")="n"
end if

if len(Request.Form("oridir"))>5 then
ds("oridir")=Request.Form("oridir")
else
ds("oridir")=null
end if

if  IsNumeric(Request.Form("ServerlistID2")) then ds("ServerlistID2")=Request.Form("ServerlistID2")
if  IsNumeric(Request.Form("ServerlistID3")) then ds("ServerlistID3")=Request.Form("ServerlistID3")
if  IsNumeric(Request.Form("ServerlistID4")) then ds("ServerlistID4")=Request.Form("ServerlistID4")
if  IsNumeric(Request.Form("ServerlistID5")) then ds("ServerlistID5")=Request.Form("ServerlistID5")


ds("PAY_Month")=Request.Form("PAY_Month")
ds("PAY_Season")=Request.Form("PAY_Season")
ds("PAY_halfyear")=Request.Form("PAY_halfyear")
ds("PAY_Nextyear")=Request.Form("PAY_Nextyear")
ds("PAY_2year")=Request.Form("PAY_2year")
ds("PAY_3year")=Request.Form("PAY_3year")
ds("PAY_4year")=Request.Form("PAY_4year")
ds("PAY_5year")=Request.Form("PAY_5year")

If Trim(Request.Form("onlyusebyagn"))<>"" then
ds("onlyusebyagn")=Request.Form("onlyusebyagn")
Else
ds("onlyusebyagn")=null
End If

if len(Request.Form("UAcopydir1"))>3 then
ds("UAcopyName1")=Request.Form("UAcopyName1")
ds("UAcopydir1")=LCase(Trim(Request.Form("UAcopydir1")))
ds("UAcopyabcout1")=Request.Form("UAcopyabcout1")
else
ds("UAcopyName1")=Null
ds("UAcopydir1")=Null
ds("UAcopyabcout1")=null
end If
if len(Request.Form("UAcopydir2"))>3 then
ds("UAcopyName2")=Request.Form("UAcopyName2")
ds("UAcopydir2")=LCase(Trim(Request.Form("UAcopydir2")))
ds("UAcopyabcout2")=Request.Form("UAcopyabcout2")
else
ds("UAcopyName2")=Null
ds("UAcopydir2")=Null
ds("UAcopyabcout2")=null
end If
if len(Request.Form("UAcopydir3"))>3 then
ds("UAcopyName3")=Request.Form("UAcopyName3")
ds("UAcopydir3")=LCase(Trim(Request.Form("UAcopydir3")))
ds("UAcopyabcout3")=Request.Form("UAcopyabcout3")
else
ds("UAcopyName3")=Null
ds("UAcopydir3")=Null
ds("UAcopyabcout3")=null
end If
if len(Request.Form("UAcopydir4"))>3 then
ds("UAcopyName4")=Request.Form("UAcopyName4")
ds("UAcopydir4")=LCase(Trim(Request.Form("UAcopydir4")))
ds("UAcopyabcout4")=Request.Form("UAcopyabcout4")
else
ds("UAcopyName4")=Null
ds("UAcopydir4")=Null
ds("UAcopyabcout4")=null
end If
if len(Request.Form("UAcopydir5"))>3 then
ds("UAcopyName5")=Request.Form("UAcopyName5")
ds("UAcopydir5")=LCase(Trim(Request.Form("UAcopydir5")))
ds("UAcopyabcout5")=Request.Form("UAcopyabcout5")
else
ds("UAcopyName5")=Null
ds("UAcopydir5")=Null
ds("UAcopyabcout5")=null
end If
if len(Request.Form("UAcopydir6"))>3 then
ds("UAcopyName6")=Request.Form("UAcopyName6")
ds("UAcopydir6")=LCase(Trim(Request.Form("UAcopydir6")))
ds("UAcopyabcout6")=Request.Form("UAcopyabcout6")
else
ds("UAcopyName6")=Null
ds("UAcopydir6")=Null
ds("UAcopyabcout6")=null
end If
if len(Request.Form("UAcopydir7"))>3 then
ds("UAcopyName7")=Request.Form("UAcopyName7")
ds("UAcopydir7")=LCase(Trim(Request.Form("UAcopydir7")))
ds("UAcopyabcout7")=Request.Form("UAcopyabcout7")
else
ds("UAcopyName7")=Null
ds("UAcopydir7")=Null
ds("UAcopyabcout7")=null
end If
if len(Request.Form("UAcopydir8"))>3 then
ds("UAcopyName8")=Request.Form("UAcopyName8")
ds("UAcopydir8")=LCase(Trim(Request.Form("UAcopydir8")))
ds("UAcopyabcout8")=Request.Form("UAcopyabcout8")
else
ds("UAcopyName8")=Null
ds("UAcopydir8")=Null
ds("UAcopyabcout8")=null
end If

ds("phpver")=Request.Form("phpver")

ds("ostype")=Request.Form("ostype")
ds("vdomains")=Request.Form("vdomains")
ds("nemails")=Request.Form("nemails")
ds("nemailf")=Request.Form("nemailf")
ds("nemailml")=Request.Form("nemailml")
ds("nemailr")=Request.Form("nemailr")
ds("mysql")=Request.Form("mysql")
ds("domainptr")=Request.Form("domainptr")
ds("ftp")=Request.Form("ftp")
ds("aftp")=Request.Form("aftp")
If Request.Form("aftp")="" Then ds("aftp")="OFF"
ds("suspend_at_limit")=Request.Form("suspend_at_limit")
If Request.Form("suspend_at_limit")="" Then ds("suspend_at_limit")="OFF"
ds("skin")=Request.Form("skin")
If Request.Form("skin")="" Then ds("skin")="enhanced"
ds("language")=Request.Form("language")
If Request.Form("language")="" Then ds("language")="en"
'packagename=ds("packagename")


'If ds("ostype")="linux" Then ds("Maxbytes")=CDbl(Request.Form ("Maxbytes"))


ds("isagentpd")=Request.Form ("isagentpd")
If ds("isagentpd")=true Then 
ds("ServerlistID")=0
ds("HostComName")=Request.Form ("HostComName")
ds("HostApiName")=Replace(replace(lcase(trim(Request.Form ("HostApiName"))),"http://",""),"/hostadm/","")
ds("Hostcpdomain")=Replace(replace(lcase(trim(Request.Form ("Hostcpdomain"))),"http://",""),"/hostadm/","")
ds("Agnuserid")=Request.Form ("Agnuserid")
ds("Domain_Agent_nonemd5_6")=Request.Form ("Domain_Agent_nonemd5_6")
ds("Agnidc")=Request.Form ("Agnidc")
ds("Agnproductid")=Request.Form ("Agnproductid")

Set dsph = Server.CreateObject("ADODB.Recordset")	
Sql="Select * from FreeHost.FreeHost_Product_Host where Hosttype='"&ds ("Hosttype")&"'"
	dsph.Open Sql,conn,1,3
while not dsph.Eof
dsph("isagentpd")=ds("isagentpd")
dsph("HostComName")=ds("HostComName")
dsph("HostApiName")=ds("HostApiName")
dsph("Hostcpdomain")=ds("Hostcpdomain")
dsph("Agnuserid")=ds("Agnuserid")
dsph("Domain_Agent_nonemd5_6")=ds("Domain_Agent_nonemd5_6")
dsph("Agnidc")=ds("Agnidc")
dsph("Agnproductid")=ds("Agnproductid")
dsph.update
dsph.movenext
wend
dsph.close
set dsph=Nothing
Else
ds("isagentpd")=false
End if



ds.Update

if Request.Form ("modify")<>"修改" Then
ds.close
Set ds = Server.CreateObject("ADODB.Recordset")	
	Sql="Select * from FreeHost.FreeHost_HostProductlist order by id desc"
	ds.Open Sql,conn,1,3
ds("packagename")=ds("id")
ds.Update
End if

If ds("ostype")="linux" Then
	Set dsserver = Server.CreateObject("ADODB.Recordset")	
	Sql="Select * from FreeHost.FreeHost_Serverlist where id='"&ds ("ServerlistID")&"' and ostype='linux'"
	dsserver.Open Sql,conn,1,1
if not dsserver.Eof Then

While not dsserver.Eof
cgi="OFF"
php="OFF"
If ds("cgi")="y" Then cgi="ON"
If ds("php")="y" Then php="ON"
URL=dsserver("site")
FreeHostsharekey=dsserver("FreeHostsharekey")
InCmd="CMD_API_MANAGE_USER_PACKAGES"
PostBody="bandwidth="&CDbl(CDbl(ds("Maxbytes"))/1024/1024)&"&quota="&ds("spacelimt")&"&vdomains="&ds("vdomains")&"&nsubdomains="&ds("allowdomain")&"&nemails="&ds("nemails")&"&nemailf="&ds("nemailf")&"&nemailml="&ds("nemailml")&"&nemailr="&ds("nemailr")&"&mysql="&ds("mysql")&"&domainptr="&ds("domainptr")&"&ftp="&ds("ftp")&"&cgi="&cgi&"&php="&PHP&"&spam=ON&catchall=ON&ssl=OFF&cron=ON&sysinfo=ON&suspend_at_limit="&ds("suspend_at_limit")&"&skin="&ds("skin")&"&language="&ds("language")&"&packagename="&ds("packagename")&"&add=Save"
PostBody=Replace(PostBody,"bandwidth=0","ubandwidth=ON")
retstr=DAAPIPOST(URL,"sefreehost",FreeHostsharekey,InCmd,PostBody)

If InStr(retstr,"text=Saved")>1 Then
'response.write "返回信息:"&retstr
'response.write ",产品包建立成功."
'response.End
else
response.write "建立出错:返回信息:"&retstr
response.End
End If

dsserver.movenext
wend

Else
response.write "此产品没有关联的服务器"
End if
End if

if Request.Form ("modify")="修改" and Request.Form ("batchAction")="y" Then%>
下面批理处理此产品所有的虚拟主机的IIS连接数及带宽(不包含子目录站)<br>
<%Set dsph = Server.CreateObject("ADODB.Recordset")	
Sql="Select * from FreeHost.FreeHost_Product_Host where Hosttype='"&Request.Form ("Hosttype")&"' and Hosttype<>'子目录绑定'"
	dsph.Open Sql,conn,1,1

On Error Resume next

while not dsph.Eof
	Set dsserver = Server.CreateObject("ADODB.Recordset")	
	Sql="Select * from FreeHost.FreeHost_Serverlist where id='"&dsph ("ServerlistID")&"' and ostype='windows'"
	dsserver.Open Sql,conn,1,1
if not dsserver.Eof Then
username=dsph("Ftpname")
URL=dsserver("site")
MaxConnections=ds ("MaxConnections")
'EnumAppsInPool=dshost ("AppPoolnum")
MaxBandwidth=ds("MaxBandwidth")
FreeHostsharekey=dsserver("FreeHostsharekey")

temp=ModifyUser2(URL,FreeHostsharekey,username,comment,homedir,spacelimit,starttime,endtime,type1,type2,type3,email,host,hostcomment,MaxConnections,EnumAppsInPool,DefaultDoc,ScriptMaps,AccessFlags,LogFileDirectory,HttpErrors,MaxBandwidth)
%>

处理ftp用户:<%=username%><br><%=temp%><br>
<%
End if
dsph.movenext
wend
dsph.close
set dsph=nothing

response.end
End if

Else


If ds("ostype")="linux" Then
	Set dsserver = Server.CreateObject("ADODB.Recordset")	
	Sql="Select * from FreeHost.FreeHost_Serverlist where id='"&ds ("ServerlistID")&"' and ostype='linux'"
	dsserver.Open Sql,conn,1,1
if not dsserver.Eof Then

While not dsserver.Eof
URL=dsserver("site")
FreeHostsharekey=dsserver("FreeHostsharekey")
InCmd="CMD_API_MANAGE_USER_PACKAGES"
PostBody="delete1="&ds("packagename")&"&delete=Delete+Selected"
retstr=DAAPIPOST(URL,"sefreehost",FreeHostsharekey,InCmd,PostBody)

If InStr(retstr,"text=Deleted")>1 Then
'response.write "返回信息:"&retstr
'response.write ",产品包删除成功."
'response.End
else
response.write "删除出错:返回信息:"&retstr
response.End
End If

dsserver.movenext
wend

Else
response.write "此产品没有关联的服务器"
End if
End if

ds.delete
end if
ds.Update

ds.Close
set ds=nothing
conn.Close 
set conn=nothing
Response.Redirect "product-host.asp"
end if

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