<!--#include virtual="/incs/config.asp" -->

<%chk_log()%>
  <%
chk_newpwr 1,4,4
	conn.open constr
	
	domainname=trim(SafeRequest("domainname"))
	if domainname="" then
	call errorpage(-2,"对不起，请选择域名！")
	end if
	
	if session("agentname")<>"" and  mid(session("oldpower"),7,1)<>"1" then
call errorpage(-2,"对不起，您没有产品管理权限")
end if

	
	
if session("sysclass")>=5 then
query="select * from v_dmelst   where d_dme ='"&domainname&"'"
elseif session("sysclass")>=4 then
query="select * from v_dmelst  where d_dme ='"&domainname&"'  and  ((("&session("sysarestr")&" or u_myare=0) and u_rotnme='') or u_rotnme='"&session("usrname")&"')"
else
query="select * from v_dmelst  where d_unme='"&session("usrname")&"' and d_dme ='"&domainname&"'"
end if
	rs.open query,conn,1,1
	if rs.recordcount<=0 then
	    call errorpage(-2,"对不起，该域名不存在！")
        elseif rs("d_regstt")<>1 then
            call errorpage(-2,"对不起，该域名不处于正常状态，无法操作!")
		    response.end
        elseif rs("d_exptme")<now() then
            call errorpage(-2,"对不起，该域名已经过期，无法操作!")
		    response.end
		end if
			did =rs("d_id")

rs.close		
Select Case SafeRequest("module")
 case "whoismodifyowner"
   substrContent = "entryclass:dme_mng"&Vend
   substrContent =substrContent& "entrytype:whoismodifyowner"&Vend
   substrContent =substrContent& "entryuser:"&entryuser&Vend
   substrContent =substrContent& "entrypass:"&entrypass&Vend
   substrContent =substrContent& "agentname:"&agentname&Vend
   substrContent =substrContent& "agentpass:"&agentpass&Vend
   substrContent = substrContent & "domainname:" & domainname & Vend
  substrContent = substrContent & "dom_adr1:" & trim(SafeRequest("dom_adr1")) & Vend
   substrContent = substrContent & "dom_ct:" & trim(SafeRequest("dom_ct")) & Vend
   substrContent = substrContent & "dom_st:" & trim(SafeRequest("dom_st")) & Vend
   substrContent = substrContent & "dom_co:" & trim(SafeRequest("dom_co")) & Vend
   substrContent = substrContent & "dom_pc:" & trim(SafeRequest("dom_pc")) & Vend
   substrContent = substrContent & "dom_ph:" & trim(SafeRequest("dom_ph")) & Vend
   substrContent = substrContent & "dom_fax:" & trim(SafeRequest("dom_fax"))& Vend
   substrContent = substrContent & "dom_em:" & trim(SafeRequest("dom_em")) & Vend
   substrContent = substrContent & "dom_co_cn:" & trim(SafeRequest("dom_co_cn")) & Vend
   substrContent = substrContent & "dom_adr1_cn:" & trim(SafeRequest("dom_adr1_cn")) & Vend
   substrContent = substrContent & "dom_ct_cn:" & trim(SafeRequest("dom_ct_cn")) & Vend
   substrContent = substrContent & "dom_st_cn:" & trim(SafeRequest("dom_st_cn")) & Vend
   substrContent = substrContent & "dom_org_cn:" & trim(SafeRequest("dom_org_cn")) & Vend
   substrContent = substrContent & "dom_ln_cn:" & trim(SafeRequest("dom_ln_cn")) & Vend
   substrContent = substrContent & "dom_fn_cn:" & trim(SafeRequest("dom_fn_cn")) & Vend
   substrContent = substrContent & "." & Vend
case "whoismodifyadmin"

   substrContent = "entryclass:dme_mng"&Vend
   substrContent =substrContent& "entrytype:whoismodifyadmin"&Vend
   substrContent =substrContent& "entryuser:"&entryuser&Vend
   substrContent =substrContent& "entrypass:"&entrypass&Vend
   substrContent =substrContent& "agentname:"&agentname&Vend
   substrContent =substrContent& "agentpass:"&agentpass&Vend
   substrContent = substrContent & "domainname:" & domainname & Vend
    substrContent = substrContent & "admi_adr1:" & trim(SafeRequest("admi_adr1")) & Vend
   substrContent = substrContent & "admi_ct:" & trim(SafeRequest("admi_ct")) & Vend
   substrContent = substrContent & "admi_st:" & trim(SafeRequest("admi_st"))& Vend
   substrContent = substrContent & "admi_fn:" & trim(SafeRequest("admi_fn")) & Vend
   substrContent = substrContent & "admi_ln:" & trim(SafeRequest("admi_ln")) & Vend
   substrContent = substrContent & "admi_co:" & trim(SafeRequest("admi_co")) & Vend
   substrContent = substrContent & "admi_pc:" & trim(SafeRequest("admi_pc")) & Vend
   substrContent = substrContent & "admi_ph:" & trim(SafeRequest("admi_ph")) & Vend
   substrContent = substrContent & "admi_fax:" & trim(SafeRequest("admi_fax")) & Vend
   substrContent = substrContent & "admi_em:" & trim(SafeRequest("admi_em")) & Vend
   substrContent = substrContent & "admi_adr1_cn:" & trim(SafeRequest("admi_adr1_cn")) & Vend
   substrContent = substrContent & "admi_co_cn:" & trim(SafeRequest("admi_co_cn")) & Vend
   substrContent = substrContent & "admi_ct_cn:" & trim(SafeRequest("admi_ct_cn")) & Vend
   substrContent = substrContent & "admi_st_cn:" & trim(SafeRequest("admi_st_cn")) & Vend
   substrContent = substrContent & "admi_ln_cn:" & trim(SafeRequest("admi_ln_cn")) & Vend
   substrContent = substrContent & "admi_fn_cn:" & trim(SafeRequest("admi_fn_cn")) & Vend
   substrContent = substrContent & "." & Vend

	case "whoismodifytech"
 substrContent = "entryclass:dme_mng"&Vend
   substrContent =substrContent& "entrytype:whoismodifytech"&Vend
   substrContent =substrContent& "entryuser:"&entryuser&Vend
   substrContent =substrContent& "entrypass:"&entrypass&Vend
   substrContent =substrContent& "agentname:"&agentname&Vend
   substrContent =substrContent& "agentpass:"&agentpass&Vend
   substrContent = substrContent & "domainname:" & domainname & Vend
   substrContent = substrContent & "tech_adr1:" & trim(SafeRequest("tech_adr1")) & Vend
   substrContent = substrContent & "tech_ct:" & trim(SafeRequest("tech_ct")) & Vend
   substrContent = substrContent & "tech_st:" & trim(SafeRequest("tech_st")) & Vend
   substrContent = substrContent & "tech_fn:" & trim(SafeRequest("tech_fn")) & Vend
   substrContent = substrContent & "tech_ln:" & trim(SafeRequest("tech_ln")) & Vend
   substrContent = substrContent & "tech_co:" & trim(SafeRequest("tech_co")) & Vend
   substrContent = substrContent & "tech_pc:" & trim(SafeRequest("tech_pc")) & Vend
   substrContent = substrContent & "tech_ph:" & trim(SafeRequest("tech_ph")) & Vend
   substrContent = substrContent & "tech_fax:" & trim(SafeRequest("tech_fax")) & Vend
   substrContent = substrContent & "tech_em:" & trim(SafeRequest("tech_em")) & Vend
   substrContent = substrContent & "tech_adr1_cn:" & trim(SafeRequest("tech_adr1_cn")) & Vend
   substrContent = substrContent & "tech_co_cn:" &trim(SafeRequest("tech_co_cn")) & Vend
   substrContent = substrContent & "tech_ct_cn:" &trim(SafeRequest("tech_ct_cn")) & Vend
   substrContent = substrContent & "tech_st_cn:" & trim(SafeRequest("tech_st_cn")) & Vend
   substrContent = substrContent & "tech_ln_cn:" & trim(SafeRequest("tech_ln_cn")) & Vend
   substrContent = substrContent & "tech_fn_cn:" & trim(SafeRequest("tech_fn_cn")) & Vend
   substrContent = substrContent & "." & Vend
    
  	case "whoismodifybilling"
 substrContent = "entryclass:dme_mng"&Vend
   substrContent =substrContent& "entrytype:whoismodifybilling"&Vend
   substrContent =substrContent& "entryuser:"&entryuser&Vend
   substrContent =substrContent& "entrypass:"&entrypass&Vend
   substrContent =substrContent& "agentname:"&agentname&Vend
   substrContent =substrContent& "agentpass:"&agentpass&Vend
   substrContent = substrContent & "domainname:" & domainname & Vend
   substrContent = substrContent & "bill_adr1:" & trim(SafeRequest("bill_adr1")) & Vend
   substrContent = substrContent & "bill_ct:" & trim(SafeRequest("bill_ct")) & Vend
   substrContent = substrContent & "bill_st:" & trim(SafeRequest("bill_st")) & Vend
   substrContent = substrContent & "bill_fn:" & trim(SafeRequest("bill_fn")) & Vend
   substrContent = substrContent & "bill_ln:" & trim(SafeRequest("bill_ln")) & Vend
   substrContent = substrContent & "bill_co:" & trim(SafeRequest("bill_co")) & Vend
   substrContent = substrContent & "bill_pc:" & trim(SafeRequest("bill_pc")) & Vend
   substrContent = substrContent & "bill_ph:" & trim(SafeRequest("bill_ph")) & Vend
   substrContent = substrContent & "bill_fax:" & trim(SafeRequest("bill_fax")) & Vend
   substrContent = substrContent & "bill_em:" & trim(SafeRequest("bill_em")) & Vend
   substrContent = substrContent & "bill_adr1_cn:" & trim(SafeRequest("bill_adr1_cn")) & Vend
   substrContent = substrContent & "bill_co_cn:" & trim(SafeRequest("bill_co_cn")) & Vend
   substrContent = substrContent & "bill_ct_cn:" & trim(SafeRequest("bill_ct_cn")) & Vend
   substrContent = substrContent & "bill_st_cn:" & trim(SafeRequest("bill_st_cn")) & Vend
   substrContent = substrContent & "bill_ln_cn:" & trim(SafeRequest("bill_ln_cn")) & Vend
   substrContent = substrContent & "bill_fn_cn:" & trim(SafeRequest("bill_fn_cn"))& Vend
   substrContent = substrContent & "." & Vend
 
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
	end select
   doresult = hzsocket(substrContent)
   left5=left(doresult,5)
   If left5= "10000" Then
      call okpage( "/master/pdtmng/dme_mng/dme_ctt.asp?dnme=" & domainname)
   Else
      call errorpage(-2,doresult)
   end if

conn.close

%>

