<!--#include virtual="/incs/config.asp"-->
<!--#include virtual="/incs/md5.asp"-->
<%chk_log_usr()
 %>
<% 
conn.open constr

query="select * from onlcfg where p_tpe=2"
rs.open query,conn,1,1
if not rs.eof then
pl_onlid = Trim(rs("p_usr"))
onlpass = Trim(rs("p_pss"))
p_payout=trim(rs("p_payout"))
p_paybck=trim(rs("p_paybck"))
end if
rs.close
if  trim(pl_onlpay_url)="" then
call errorpage(-2,"对不起，该功能 暂时关闭！")
end if
v_amount=SafeRequestform("amount")
if chk_int(v_amount)=false then
call errorpage(-2,"对不起，输入金额有误！")
end if

if v_amount<=0 then
call errorpage(-2,"对不起，输入金额应该是大于0的整数！")
end if
if instr(v_amount,".")>0 then 
call errorpage(-2,"对不起，输入金额应该是大于0的整数！")
end if
query="select *from memdtl where u_nme='"&session("usrname")&"'"
rs.open query,conn,1,1
if rs.recordcount<>1 then
call errorpage(-2,"对不起，意外错误！")
response.end
else
u_nme=trim(rs("u_nme"))
u_eml=trim(rs("u_eml"))
u_tel=trim(rs("u_tel"))
productname="payonline"
u_cde=trim(rs("u_cde"))
u_adr_cn=trim(rs("u_adr_cn"))
v_mid=pl_onlid
v_email=u_eml
v_mobile=trim(rs("u_mbl"))
if v_mobile="" then
v_mobile=trim(rs("u_tel"))
v_mobile=replace(v_mobile,"-","")
end if
if v_modile="" then
v_mobile="13845678901"
end if
content="http://"&request.servervariables("server_name")
end if
rs.close 

query = "select * from onlcfg where p_tpe=2"
rs.Open query, conn, 1, 1
If rs.EOF Then
call errorpage(-2,"对不起，系统配置错误！1")
End If
onlpass = Trim(rs("p_pss"))
rs.Close
onlpass=getoutcodelong(onlpass)
v_key=onlpass
if onlpass="" then
call errorpage(-2,"对不起，系统设置错误！2")
end if

query="insert into onlpay(v_mid,v_amount,v_rname,v_remail,v_rtel,v_pmd5,addtime,addip,username,fathercon) values("&v_mid&","&v_amount&",'"&u_nme&"','"&u_eml&"','"&u_tel&"','',getdate(),'"&request.servervariables("remote_addr")&"','"&session("usrname")&"','')"
conn.execute query,1,1
if conn.errors.count=0 then
findlastid  v_oid
else
call errorpage(-2,"对不起，意外错误！")
end if  

v_md5=md5(v_mid&v_oid&v_amount&v_email&v_mobile&v_key)

%>
<HTML><HEAD><TITLE><%=pl_stenme%>-银行在线支付</TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<SCRIPT language=JavaScript>
function conFirmAmount()
{
	var stConFirm = '您的转帐金额为: ' + document.netbank.amount.value + ' 元';
	return confirm(stConFirm);
}
</SCRIPT>

<STYLE>TD {
	FONT-SIZE: 9pt; LINE-HEIGHT: 14pt
}
</STYLE>

<META content="MSHTML 6.00.2800.1226" name=GENERATOR></HEAD>
<BODY bgColor=#ffffff leftMargin=0 topMargin=0 marginheight="0" marginwidth="0">
<br>
<br>
<br>
<TABLE height=400 cellSpacing=0 cellPadding=0 width=500 
background=../pay_img/cmbchinabg.jpg border=0 align="center" style="border:#000000 1px double">
  <TBODY> 
  <TR>
    <TD vAlign=top>
      <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
        <TBODY>
        <TR>
          <TD><IMG height=86 src="../pay_img/blank.gif" width=10></TD>
          <TD>&nbsp;</TD></TR>
        <TR>
          <TD width=236><img height=1 src="../pay_img/blank.gif" 
            width=236></TD>
          <TD vAlign=top>
            <P>请填入您要转帐的金额，转帐成功的话， <BR>该款项将直接划入您在本系统帐户上。 
            <BR>如果您正在进行交易，请确保您转帐的<BR>金额不少于您的交易金额。</P>
	 <form action="<%=p_payout%>" method="post" name="post">
<INPUT type=hidden  name=v_amount value="<%=v_amount%>">
<INPUT type=hidden  name=v_name value="<%=u_name%>">
 <INPUT type=hidden  name=v_email  value="<%=u_eml%>">
  <INPUT type=hidden  name=v_mid  value="<%=v_mid%>">
  <input type=HIDDEN name="v_oid"     value="<%=v_oid%>">
  <input type=HIDDEN name="v_mobile"     value="<%=v_mobile%>">
  <input type=HIDDEN name="v_md5"     value="<%=v_md5%>">
            <TABLE cellSpacing=8 cellPadding=5 width="90%" border=0>  
              <TBODY>
              <TR>
                <TD>请再次确认您输入的金额。</TD></TR>
              <TR>
                <TD>划帐金额： <INPUT size=18   name=amount value="<%=v_amount%>" disabled=1></TD></TR>
              <TR>
                <TD align=middle><INPUT type=image height=25 width=136 
                  src="../pay_img/cmbsubmit.gif" 
            border=0></TD></TR></TBODY></TABLE></FORM>
            <P>&nbsp;</P></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></BODY></HTML>
