Command deleted all character

Results 1 to 5 of 5
  1. #1
    Member gunzhelp is offline
    MemberRank
    Jan 2011 Join Date
    90Posts

    Command deleted all character

    Hello,

    Please help me command deleted all account banned 253 in mssql


    thanks.


  2. #2
    Doggie And Rice. Military is offline
    MemberRank
    Jun 2009 Join Date
    Here and AboutLocation
    3,302Posts

    Re: Command deleted all character

    Can you please explain yourself better?

  3. #3
    Valued Member gaspartx is offline
    MemberRank
    Apr 2009 Join Date
    BrazilLocation
    102Posts

    Re: Command deleted all character

    PHP Code:
    <?
    //Script By Gaspar

    include "your_config.php";

    $busca1 mssql_query("SELECT TOP 99999 AID FROM Account WHERE UGradeID = '253'");
    while(
    $busca2 mssql_fetch_row($busca1)){

    $delete1 mssql_query("DELETE FROM AccountItem WHERE AID = '$busca2[0]'");

    $delete2 mssql_query("DELETE FROM CharacterItem WHERE AID = '$busca2[0]'");

    $delete3 mssql_query("DELETE FROM Character WHERE AID = '$busca2[0]'");

    $delete4 mssql_query("DELETE FROM Login WHERE AID = '$busca2[0]'");

    $delete5 mssql_query("DELETE FROM Account WHERE AID = '$busca2[0]';

    }

    echo "
    All banned accounts deleted successfully";

    ?>
    Save this file in PHP and run on your website.

    Do not forget to edit your config.php file in startup time.
    Last edited by gaspartx; 12-04-11 at 02:15 AM.

  4. #4
    DRGunZ 2 Creator wesman2232 is offline
    MemberRank
    Jan 2007 Join Date
    Erie, PALocation
    4,872Posts

    Re: Command deleted all character

    Where is the * in those querys?
    Shouldn't it be
    PHP Code:
    DELETE FROM AccountItem WHERE AID '$busca2[0]' 
    ?
    Or can you do it without?

  5. #5
    Banned Blasian is offline
    BannedRank
    Aug 2009 Join Date
    California, USLocation
    773Posts

    Re: Command deleted all character

    PHP Code:
    <?php
    //Coded by Dude3889

    include "config.php";

    function 
    checkban(){
    $query mssql_query("SELECT * FROM Account WHERE AID = '"$_SESSION['AID']."'");
    $getbanned mssql_fetch_assoc($query);
      if(
    $getbanned['Ugrade']==253){ 
        if(
    $getbanned['perm']==1){
            
    $delete mssql_query("DELETE FROM AccountItem WHERE AID = '".$_SESSION['AID']."'");
            
    $delete1 mssql_query("DELETE FROM CharacterItem WHERE AID = '".$SESSION['AID']."'");
            
    $delete2 mssql_query("DELETE FROM Character WHERE AID = '".$_SESSION['AID']."'");
        } else {
            echo 
    "Your Ban Ends On'".$getbanned['BanEnd']."'";
        }
    echo 
    "Your Not even Banned";
    }
    }

    ?>
    Added Tables to account named,
    BanEnd(date)
    Perm 1 = Banned forever 0 = Not
    If the user is banned forever it will delete
    date time will not automatically unban but that's easy to code.
    I would put this in your login script so that when the user logins in the site it will ban delete it all, adding this to a account info page would be cool. this was coded in 5 minutes and may not work fully but easy to fix gl.



Advertisement