<?
//*********************************************************************************
// Original Website By : Niadesain.com Di Jual melalui http://niadesain.com
// Please Call / SMS : 081384745483 (support@niadesain.com)
// Niadesain.com - Jasa Pembuatan Website Paling Murah dan Paling Lengkap
//*********************************************************************************
?>
<title>Konfirmasi</title>
<style type="text/css">
<!--
.spasi {	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 10px;
	line-height: 22px;
}
.style3 {color: #F1F1E2}
.style4 {font-size: 9px}
.style6 {
	color: #FF0000;
	font-weight: bold;
}
-->
</style>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td colspan="3" height="25" bgcolor="#E7E5D9"><div align="center"><strong>PAYMENT 
        CONFIRMATION</strong></div></td>
  </tr>
  <tr>
    <td colspan="3" bgcolor="#CCCCCC"><img src="../images/px1.gif" width="1" height="1" alt="" border="0"></td>
  </tr>
  <tr>
    <td width="1" rowspan="3" bgcolor="#CCCCCC"><img src="../images/px1.gif" width="1" height="1" alt="" border="0"></td>
    <td width="956" height="3" bgcolor="#EF9400"><img src="../images/px1.gif" width="1" height="1" alt="" border="0"></td>
    <td width="1" rowspan="3" bgcolor="#CCCCCC"><img src="../images/px1.gif" width="1" height="1" alt="" border="0"></td>
  </tr>
  <tr>
    <td valign="top">
<p>
  <?	
if($page == "form") {	
?>
</p>
<form name="form1" method="post" action="?m=konfirmasi&page=kirim">
        <table width="72%"  border="0" align="center" cellpadding="2" cellspacing="0" class="isi">

          <tr>
            <td colspan="2"><p><em><strong>Please fill this confirmation form below: </strong></em></p></td>
          </tr>
          <tr>
            <td colspan="2" align="center">&nbsp;</td>
          </tr>
          <tr>
            <td width="37%">Amount</td>
            <td width="63%">: 
              <input name="nominal" type="text" class="form" id="nominal" size="10">
              <span class="spasi">
              <input name="new" type="hidden" class="form" id="new" value="<?= $new; ?>" size="10">
              </span></td>
          
          <tr>
            <td>Transfer date</td>
            <td>:
              <input name="tgl" type="text" class="form" id="tgl" size="2" maxlength="2">
              -
              <input name="bln" type="text" class="form" id="bln" size="2" maxlength="2">
              -
              <input name="thn" type="text" class="form" id="thn" size="4" maxlength="4" />
              (dd-mm-yyyy)           </td>
          </tr>
          <tr>
            <td>Transfer by bank (name of bank)</td>
            <td>:              
            <input name="bankasal" type="text" class="form" id="bankasal" size="30" /></td>
          </tr>
          <tr>
            <td colspan="2" align="center" bgcolor="#E7E5D9"><strong>YOUR BANK ACCOUNT </strong></td>
          </tr>
          <tr class="bodytext">
            <td valign="top">Bank<br />
            (bank, acc. no, acc..name) </td>
            <td>&nbsp;
              <textarea name="bank" cols="30" rows="3" class="form" id="bank"><?= dataku("bank", $user_session); ?></textarea> 
            <br></td>
          </tr>
          <tr valign="top">
            <td>Note</td>
            <td>&nbsp;
                <textarea name="catatan" cols="30" rows="3" class="form" id="textarea3"></textarea>            </td>
          </tr>
          <tr>
            <td>&nbsp;<b><font face="Verdana, Arial, Helvetica, sans-serif" size="2" color="#000000">
              <input name="username" type="hidden" id="downline3"  value="<?php echo "$user_session"; ?>" size="20">
              <input name="nama" type="hidden" id="nama"  value="<?php echo dataku("nama", $user_session); ?>" size="20" />
              <input name="sponsor" type="hidden" id="sponsor"  value="<?php echo $user_sponsor; ?>" size="20">
              <input name="email" type="hidden" id="email"  value="<?php echo $user_email; ?>" size="20">
              <input name="spmail" type="hidden" id="spmail" value="<?php echo "$s_mail"; ?>" size="60" />
              <input name="upline" type="hidden" id="upline"  value="<?php echo dataupline("upline0", $user_session); ?>" size="20" />
            </font></b></td>
            <td><input name="Submit" type="submit" class="tombol" value="SUBMIT"></td>
          </tr>
          <tr>
            <td colspan="2">&nbsp;</td>
          </tr>
          <tr>
            <td colspan="2" class="spasi"><p class="style6">&nbsp;</p>              </td>
          </tr>
        </table>
</form>
        <?
}
if($page == "kirim") {
	$sp1= dataupline("upline0", $user_session);
		if($new == 1) {
			$rpsp0 = $rpsp;
			$rpsp1 = '';
			$kirime = "Sponsor : ".rupiah($rpsp0)."";
		} else {
			$rpsp1 = $rpsp1;
			$rpsp0 = '';
		}
		
	$tgltransfer = "$tgl-$bln-$thn";	
	if (!$nominal || !$tgl || !$bln) {
  		
  	echo "<font color=red><b>Please fill the form.</font><br> Click BACK button to retry.</b>";
	} else {	
 
  //-----------kirim email ke admin---------------
   $isimail="This member has confirmed his/her transfer to upgrade meembership\n\n"
  		   ."Name              : $user_nama\n"
		   ."Username          : $user_session\n"
		   ."Sponsor           : $user_sponsor\n"
		   ."Transfer date     : $tgltransfer\n"
		   ."Transfer by       : $bankasal\n"
		   ."Other bank        : $rekening\n"
		   ."Bank Account      : $bank\n"
		   ."                  : $norek\n"
		   ."                  : $anbank\n"
		   ."Transfer amount   : ".rupiah($nominal)." (Pengelola)\n"
		   ."Note              : $catatan\n\n"
		  
		   ."Thank You.\n\n$user_nama";
		   
		$headers = "From: $nama<$email>\nX-Sender: $email\n";
        $subject ="Transfer Confirmation";
//--email ke admin -----------
		$em_admin=config("email");
		@mail($em_admin, $subject, $isimail, $headers);
	
	//------email ke sponsor--------
	$emsp = dataku("email", $user_sponsor);
	@mail($emsp, $subject, $isimail, $headers);
?>
      
<table width="98%"  border="0" align="center" cellpadding="2" cellspacing="0" class="form">
  <tr>
    <td height="25">
        
          <p align="center"><strong>THANK YOU</strong></p>
          <p>
          
            </p>
          <p align="center">You have confirmed your payment.<br />
              Your membership will be activated in 24 hours.<br />
          </p>
          <p>&nbsp;</p>
          <p align="center">Best regards,</p>
          <p>&nbsp;		  </p>
          <p align="center"><strong><em>Admin <?= $domain; ?></em> </strong></p>
          </td>
  </tr>
  <tr>
    <td height="25">&nbsp;</td>
  </tr>
</table>


<?

	
	}
}
?>
    </td>
  </tr>
  <tr>
    <td height="1" background="../images/t_fon.gif" bgcolor="#CCCCCC"><img src="../images/px1.gif" width="1" height="1" alt="" border="0"></td>
  </tr>
  <tr>
    <td colspan="3" align="right">&nbsp;</td>
  </tr>
</table>
