View file public_html/vipadz/ucpayall.php

File size: 3.42Kb
<?php

/************************************

Script : Adnetwork
Website : http://facebook.com/mohd.arshadsaifi79

Script is created and provided by Arshad (http://facebook.com/mohd.arshadsaifi79)
**************************************/
include '../db.php';
include '../functions.php';

headtag("$SiteName - Pay Ucweb Payments To All Users");

if($adminlog=='1'){
$lastmonth=date("F", time()-2592000);
$lul = mysql_query('SELECT username from userdata WHERE ucstatus="1" AND uclast!="0" AND lastucpay="Pending" AND status="ACTIVE"');
while(list($user) = mysql_fetch_row($lul)){
$arshad = mysql_query("SELECT * FROM userdata WHERE username='$user'");
$mohd = mysql_fetch_array($arshad);
$uclast=$mohd["uclast"];
$usern=$mohd["username"];
$pubalance=$mohd["pubalance"];
$mobile=$mohd["mobile"];
$email=$mohd["email"];
$date=date("l , F d , Y"); 
if(isset($_POST["captcha"]))
{
$captcha=formpost("captcha");
$month=formpost("month");
if($_SESSION["captcha"]!=$captcha){
 echo '';
}

else
{

mysql_query("INSERT INTO notifications (user, news , other, stat)
VALUES ('$usern', 'Congratulations We Have Paid 100% Of Your Apps Installation Earnings Till ".$month." Month Installation..', 'none', 'none')");
mysql_query("INSERT INTO ucpay (user, amount , deduction, reason, month)
VALUES ('$usern', '$uclast', '0', '', '$month,2016')");
  $newbal=($pubalance+$uclast);
 $doit=mysql_query("UPDATE userdata SET pubalance='$newbal',uclast='0',lastucpay='Paid' WHERE username='$user'");
if($mobile!='')
{
$msg = "Hello $usern ,
We have paid 100% of your apps installation earnings till $month month installation to your main account.
Thanks for using EarnBuzz.In";
Send_SMS($mobile,$msg);
}

$to = $email;
$subject = "Payment of Apps Installation";
$body = 'Hello '.$usern.'! <br/>
We have paid 100% of your apps installation earnings till '.$month.' month installation to your main account of earnbuzz. <br/>
<br/>
Total earnings- '.$uclast.' $ <br/>
<br/>
Login to earnbuzz and check your balance. <br/>
<br/>
Thanks for using EarnBuzz.In <br/>
<br/>
If you have any query contact us';
mysql_query("INSERT INTO mails (email,subject,body,status) VALUES ('$email','$subject','$body','Pending')");


if($doit){
  echo '<div class="success">'.$usern.' Ucweb Payment Paid.</div>';
}
else
{
	  echo '<div class="error">'.$usern.' Ucweb Payment Error.</div>';
}
 }
}
}
echo '<div class="form"><form method="post">Month:<br/><select name="month">    
                                <option value="'.$lastmonth.'" selected="yes">'.$lastmonth.'</option>
               <option value="January">January</option>
               <option value="February">February</option>
               <option value="March">March</option>
               <option value="April">April</option>
               <option value="May">May</option>
               <option value="June">June</option>
               <option value="July">July</option>
               <option value="August">August</option>
               <option value="September">September</option>
                <option value="October">October</option>
               <option value="November">November</option>
	      <option value="December">December</option>
      
</select><br/>Enter Captcha:<br/><img src="/im'.md5(microtime()).'.jpg"/><br/><input type="text" name="captcha" maxlength="5" /><br/><input type="submit" value="Pay Now"/></form></div>';
}
else {
header('Location:login.php');
}
echo '<div class="page"><a href="index.php">Home</a></div>';
include '../foot.php';
?>