Micro Niche Builder
Closed Thread
Page 1 of 3 1 2 3 LastLast
Results 1 to 10 of 21

Thread: sitemap - how long?

  1. #1

    Smile [Free] AutoSurf add-on: Viewing expired upgrade

    Well, I have tried to solve this expired->pending for a long time.. there seems to be some bug in Modified AS script that you guys send me. So this is the free tool to help you looking for expired upgrade before running your cronjob.

    Feature for this free version:
    - See list of expired upgrade from yesterday[server time] and before that date
    - See details of expired upgrades as well as currently active upgrade for that user, total invested , date purchase and expiry date.

    What available for paid version:
    - Manually setting each expire upgrade to become expired
    - Move user cash balance to Pending cash out [adjustable]
    - All features of admin cron script


    You can run this free version to see all expired upgrades and then run cronjob to see if this script is bug free. You can also fine tune this script by setting the offeset day.
    $offset=0; <- this is the default, you can change it to -1 or 1

    Instruction:
    - create new file named upgradeexpire.php
    - go into code mode
    - copy and paste the whole script below
    - if you use notepad makesure you put double quote before and after the file name "upgradeexpire.php" just to make sure that the files extension is php
    - put this file in /control/ directory
    - call it by http://xxx.com/control/upgradeexpire.php
    - username and password is the same with your admin cp
    - session vars holded for both admin CP and this script

    Please inform me of any bugs or suggestions in this thread please
    I will only answer PM for those that want the paid version only
    [integration with admin CP is also available]
    You can distribute it for free and use it at your own risk

    neversay


  2. Micro Niche Builder

  3. #2

    Default

    <?php
    session_start();
    include("../vars.php");
    include("../headfoot.php");
    mysql_connect($db_host, $db_user, $db_pwd);
    mysql_select_db($db_name);
    $day_now_is = date("Y-m-d");
    $login_screen = "<html><head><title>$title</title></head><body><br><br><br><br><div align=\"center\"><font size=\"4\" face=\"Tahoma\"><strong>$title Control Panel</strong></font></div><center><table border=\"0\" style=\"border-collapse: collapse\" bordercolor=\"#111111\" cellpadding=\"0\" cellspacing=\"3\">
    <form method=post action=".$control_url."upgradeexpire.php><input type=hidden name=form value=sent><tr>
    <td align=\"right\" valign=\"top\"><b>
    <font face=\"$fontface\" size=\"2\">Login</font>:</b></td>
    <td align=\"left\" valign=\"top\">
    <input type=\"text\" name=\"login\" size=\"25\" style=\"font-family: $fontface; font-size: 9pt; font-weight: bold\"></td>
    </tr><tr><td align=\"right\" valign=\"top\">
    <font face=\"$fontface\" size=\"2\"><b>Password:</b></font></td>
    <td align=\"left\" valign=\"top\">
    <input type=\"password\" name=\"passwd\" size=\"25\" style=\"font-size: 9pt; font-family: $fontface; font-weight: bold\"></td>
    </tr><tr><td></td><td align=\"left\" valign=\"top\">
    <input type=\"submit\" value=\"Login\" style=\"font-family: $fontface; font-size: 9pt; font-weight: bold; float: right\"></td>
    </tr></form></table></center></body></html>";
    if ($_COOKIE['ref']) {
    setcookie("ref", $_COOKIE['ref'], time()-964000);
    }
    if (!isset($_SESSION['asess_name']) || !isset($_SESSION['asess_passwd'])) {
    if ($_POST['form'] == 'sent') {
    if ($_POST['login'] == "" || $_POST['passwd'] == "") {
    echo($login_screen);
    echo("<script>alert('The admin Username or Password cannot be blank!');</script>");
    session_destroy();
    mysql_close;
    exit;
    } else {
    $_SESSION['asess_name'] = $_POST['login'];
    $_SESSION['asess_passwd'] = md5($_POST['passwd']);
    header("Location: ".$control_url."upgradeexpire.php?".session_na me() ."=".session_id());
    mysql_close;
    exit;
    }
    } else {
    echo($login_screen);
    echo("<script>alert('Your session data was not found, please login.');</script>");
    session_destroy();
    mysql_close;
    exit;
    }
    } else {
    $res = mysql_query("select value from admin where field='login'");
    $db_login = mysql_result($res, 0);
    $res = mysql_query("select value from admin where field='passwd'");
    $db_passwd = mysql_result($res, 0);
    if ($_SESSION['asess_name'] != $db_login || $_SESSION['asess_passwd'] != md5($db_passwd)) {
    echo($login_screen);
    echo("<script>alert('Invalid login, please check your admin username and password.');</script>");
    session_destroy();
    mysql_close;
    exit;
    }
    $last_log = mysql_result(mysql_query("select value from admin where field='lastaccess'"), 0);
    $last_ip = mysql_result(mysql_query("select value from admin where field='lastacip'"), 0);
    $resas = mysql_query("UPDATE admin SET value='" . time() . "' where field='lastaccess'");
    $resas = mysql_query("UPDATE admin SET value='$last_log' where field='lastac'");
    $resas = mysql_query("UPDATE admin SET value='" . $_SERVER['REMOTE_ADDR'] . "' where field='lastacip'");
    $resas = mysql_query("UPDATE admin SET value='$last_ip' where field='lastip'");
    }

    /*
    ============= Upgrade Expire Management Version 1.0 ==============
    ==== Please contact Neversay @ Talkgold.com for more updates ====
    ==== User it at your own risk ================
    ==== Can be distributed for free ========
    */
    session_start();
    include("../vars.php");
    mysql_connect($db_host, $db_user, $db_pwd);
    mysql_select_db($db_name);
    ?>

    <html>
    <head>
    <title>Upgrade Expire Management : by Neversay @ Talkgold.com</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    </head>

    <body bgcolor="#FFFFFF" text="#000000">
    <Br>
    <?
    $offset=0;

    $todaysdate = date("Y-m-d");
    $backdate =$max_invest_days+$offset;
    $invest_date = strftime("%Y-%m-%d", strtotime("$adate + $backdate days ago"));
    echo "Today date : <b>". $todaysdate."</b><br>";
    echo "Look for Upgrade made on or before : <b>".$invest_date."</b>";
    echo "<br>Upgrade last: <b>".$max_invest_days ."</b> Days.";
    echo "<br>Show records expired today or earlier";
    echo "<br><a href=upgradeexpire.php>Refresh this page</a>";
    /* ########################### SET TO EXPIRED ############################################# */
    $a=$_GET['a'];
    if ($a==1) // set to expire status
    { $usrid = $_GET['usrid'];
    $sql="SELECT * FROM user WHERE id = '$usrid' LIMIT 1";
    $get_user = mysql_query($sql);
    if (mysql_num_rows($get_user) != 0) {
    echo("<table width=\"95%\" border=\"0\" cellspacing=\"1\" cellpadding=\"2\" align=\"center\">
    <tr bgcolor=#AAAAAA>
    <td><strong><font size=\"2\">User ID</font></strong></td>
    <td><strong><font size=\"2\">Total Invested</font></strong></td>
    <td><strong><font size=\"2\">Cash Balance</font></strong></td>
    <td><strong><font size=\"2\">Last Earned</font></strong></td>
    <td><strong><font size=\"2\">Last Surfed</font></strong></td>
    <td><strong><font size=\"2\">Upgrade Status End</font></strong></td>
    <td><strong><font size=\"2\">Action</font></strong></td></tr>
    ");
    $username= mysql_result($get_user, 0, "name");
    $invested = mysql_result($get_user, 0, "invested");
    $cashbalance = mysql_result($get_user, 0, "roi_cash");
    $lastroi = mysql_result($get_user,0, "lastroi");
    $lastsurf = mysql_result($get_user, 0, "lastsurfed");
    $upgradeend = mysql_result($get_user,0, "upgrade_ends");
    //$cdate = mysql_result($get_cashouts, 0, "cashout_history.cdate");
    }
    echo("<tr bgcolor=#CCCCCC>
    <td><div align=\"center\"><font size=\"2\">$usrid:$username</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$invested</font></div></td>
    <td><div align=\"center\"><font size=\"3\" color=#AA0000>$$cashbalance</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$lastroi</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$lastsurf</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$upgradeend</font></div></td>
    <td><div align=\"center\"><font size=\"2\"></div></td>
    </tr>
    <tr height=4><td></td></tr>
    <tr bgcolor=#BBBBBB><TD>Invest ID</td><td>Invest Date</td><td>Expire Date</td><td>Amount</td><td>New Cash Balance</td><td>Cashout Amount</td><td></td></tr>
    ");
    $sql="SELECT * FROM investment_history WHERE expired='no' AND adate <= '$invest_date' AND usrid = ".$usrid." ";
    $get_investment = mysql_query($sql);
    if (mysql_num_rows($get_investment) != 0)
    {
    for ($ii = 0; $ii < mysql_num_rows($get_investment); $ii++) {
    $id = mysql_result($get_investment, $ii, "id");
    $adate = mysql_result($get_investment, $ii, "adate");
    $amount = mysql_result($get_investment, $ii, "amount");
    $expire_date = strftime("%Y-%m-%d", strtotime("$adate + $max_invest_days days"));
    echo ("<tr bgcolor=#DDDDDD><td>".$id."</td><td>".$adate."</td><td>".$expire_date."</td><td>".$amount."</td>");
    echo ("
    <form method=post action=upgradeexpire.php?a=2&payid=".$id."&usrid=" .$usrid."&invest=".$amount.">
    <td><input type=text name=balance value=\"0.00\" size=8></td><td><input type=text name=amount value=".$cashbalance." size=8></td><td><input type=submit value=\"Set to expire\"></td>
    </form>
    ");
    echo("</tr><tr><td colspan=6>**New Cash balance can not be grater than current cash balance: Cashout amount this is the amount that will go to pending</td></tr>");
    }

    }

    $sql="SELECT * FROM investment_history WHERE expired='no' AND adate > '$invest_date' AND usrid = ".$usrid." ";
    $get_investment = mysql_query($sql);
    if (mysql_num_rows($get_investment) != 0)
    {
    echo ("<tr bgcolor=#AAAAAA><td colspan=4>Active upgrades</td></tr>");
    for ($ii = 0; $ii < mysql_num_rows($get_investment); $ii++) {
    $id = mysql_result($get_investment, $ii, "id");
    $adate = mysql_result($get_investment, $ii, "adate");
    $amount = mysql_result($get_investment, $ii, "amount");
    $expire_date = strftime("%Y-%m-%d", strtotime("$adate + $max_invest_days days"));
    echo ("<tr bgcolor=#DDDDDD><td>".$id."</td><td>".$adate."</td><td>".$expire_date."</td><td>".$amount."</td></tr>");
    }

    }
    echo "</table>";
    }
    else if ($a==2)
    {
    echo "<br>Sorry this function is available for this free version: Please contact Neversay on Talkgold.com the cost is only $10";
    mysql_close;
    exit;

    }

    /* ########################## DISPLAY PENDING INFORMATION ############################# */
    //==== get ordering info
    $strorder='';
    $orderby = $_GET['by'];
    $direction=$_GET['o'];
    if ($orderby !='')
    {
    $strorder =' ORDER BY investment_history.'.$orderby. ' ' .$direction . ' ';
    }

  4. #3

    Default

    //===== search database And display ===

    $sql="SELECT *,name FROM investment_history,user WHERE expired='no' AND adate <= '$invest_date' AND investment_history.usrid = user.id ".$strorder." LIMIT 30";
    $get_investment = mysql_query($sql);
    if (mysql_num_rows($get_investment) != 0) {
    echo "<br>List of members that their upgrade should be expired:<br>";
    echo("<table width=\"95%\" border=\"0\" cellspacing=\"1\" cellpadding=\"2\" align=\"center\">
    <tr bgcolor=#AAAAAA>
    <td><strong><font size=\"2\">User ID <a href=upgradeexpire.php?by=usrid&o=ASC>A</a> <a href=upgradeexpire.php?by=usrid&o=DESC>D</a></font></strong></td>
    <td><strong><font size=\"2\">InvestID</font></strong></td>
    <td><strong><font size=\"2\">User Name</font></strong></td>
    <td><strong><font size=\"2\">Invested Date<a href=upgradeexpire.php?by=adate&o=ASC>A</a> <a href=upgradeexpire.php?by=adate&o=DESC>D</a></font></strong></td>
    <td><strong><font size=\"2\">Expired Date</font></strong></td>
    <td><strong><font size=\"2\">Amount <a href=upgradeexpire.php?by=amount&o=ASC>A</a> <a href=upgradeexpire.php?by=amount&o=DESC>D</a></font></strong></td>
    <td><strong><font size=\"2\">Description</font></strong></td>
    <td><strong><font size=\"2\">Action</font></strong></td></tr>
    ");
    for ($ii = 0; $ii < mysql_num_rows($get_investment); $ii++) {
    $user_id = mysql_result($get_investment, $ii, "investment_history.usrid");
    $invest_id = mysql_result($get_investment, $ii, "investment_history.id");
    $user_name = mysql_result($get_investment, $ii, "user.name");
    $amount = mysql_result($get_investment, $ii, "investment_history.amount");
    $descr = mysql_result($get_investment, $ii, "investment_history.descr");
    $adate = mysql_result($get_investment, $ii, "investment_history.adate");
    //$todaysdate = date("Y-m-d");
    $expire_date = strftime("%Y-%m-%d", strtotime("$adate + $max_invest_days days"));
    echo("<tr bgcolor=#CCCCCC>
    <td><div align=\"center\"><font size=\"2\">$user_id</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$invest_id</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$user_name</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$adate</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$expire_date</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$$amount</font></div></td>
    <td><div align=\"center\"><font size=\"2\">$descr</font></div></td>
    <td><div align=\"center\"><font size=\"2\"><a href=upgradeexpire.php?a=1&usrid=".$user_id.">View &Set</a></font></div></td>
    </tr>
    ");
    }
    echo("</table>");
    mysql_close;
    exit;
    } else {
    echo("<p><font face=$fontface size=2><b>No Expired records found</b></font></p>");
    }

    ?>
    </body>
    </html>

  5. #4

    Default Neversay, I'm really Confused!

    WoW,

    I forgot why I clicked on this thread
    I read your whole script now I am more
    confused than ever. What is all
    the writing about? Is this something
    important? I am willing to understand
    do want to miss too much:wink:

    Okay enough confusion I'm out

  6. #5

    Default

    Well this thread is for admin only.
    If you are not running an AS/HYIP site.. just stay away from here.

  7. #6

    Default Excuse Me!

    Sorry about that neversay,
    I did not know it was for
    whatever you say that thing is.

    No problem I will stay away.

  8. #7

  9. #8

    Default

    Quote Originally Posted by pghdd7a
    looks good ....I am in
    :biggrin: nice joke mann

  10. #9

    Smile

    Joke Haaa!

    Joke Haaa! :smile:

  11. #10

    Default

    looks pretty anvanced :P

Closed Thread
Page 1 of 3 1 2 3 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts