Total online script for offical website

Results 1 to 8 of 8
  1. #1

    Total online script for offical website

    Hello.
    I was trying to make total online in the server script for offical files but I didn't know how to continue.
    Need to count all accounts with column isuse = 'j'

    Somone can give me working script or teach me how?


  2. #2
    Member Diumelia is offline
    MemberRank
    Apr 2009 Join Date
    BelgiumLocation
    60Posts

    Re: Total online script for offical website

    PHP Code:
    <?php
    ini_set
    ('display_errors'0); 
    $connection mssql_connect('YOURHOST''sa''YOURPASSWORD'); //Change YOURHOST and YOURPASSWORD!

    if(!connection || !mssql_select_db('ACCOUNT_DBF'$connection)) 
    {
        die(
    'Unable to connect or select database!');
    }
    $query mssql_query("SELECT account FROM ACCOUNT_TBL WHERE isuse = 'J'");
    $result mssql_num_rows($query);
    echo 
    $result;
    ?>
    I didn't try it but it should work.

  3. #3

    Re: Total online script for offical website

    Quote Originally Posted by Diumelia View Post
    PHP Code:
    <?php
    ini_set
    ('display_errors'0); 
    $connection mssql_connect('YOURHOST''sa''YOURPASSWORD'); //Change YOURHOST and YOURPASSWORD!

    if(!connection || !mssql_select_db('ACCOUNT_DBF'$connection)) 
    {
        die(
    'Unable to connect or select database!');
    }
    $query mssql_query("SELECT account FROM ACCOUNT_TBL WHERE isuse = 'J'");
    $result mssql_num_rows($query);
    echo 
    $result;
    ?>
    I didn't try it but it should work.
    Thank you so much. It's working,If you'll need anything just PM me. Thanks

    Add me to your MSN if you can
    TheUnrealz@gmail.com

    edit:
    The script you gave me is a little wrong,I fixed it
    here is the fixed one:


    PHP Code:
    <?php
    ini_set
    ('display_errors'0); 
    $connection mssql_connect('YOURHOST''sa''YOURPASSWORD'); //Change YOURHOST and YOURPASSWORD!

    if(!connection || !mssql_select_db('ACCOUNT_DBF'$connection)) 
    {
        die(
    'Unable to connect or select database!');
    }
    $query mssql_query("SELECT account FROM ACCOUNT_TBL_DETAIL WHERE isuse = 'J'");
    $result mssql_num_rows($query);
    echo 
    $result;
    ?>
    Last edited by theunreal; 16-12-09 at 06:43 PM.

  4. #4
    Member Diumelia is offline
    MemberRank
    Apr 2009 Join Date
    BelgiumLocation
    60Posts

    Re: Total online script for offical website

    You're welcome! ;)

  5. #5
    Alpha Member Organic is offline
    MemberRank
    May 2007 Join Date
    2,077Posts

    Re: Total online script for offical website

    Dude, what the hell is wrong with you these days?

  6. #6
    Account Upgraded | Title Enabled! AccountDeleted is offline
    MemberRank
    Jul 2008 Join Date
    296Posts

    Re: Total online script for offical website

    That's the hard way of going about it you could just use the CCU tables where it allows you to find out what cluster/etc they're all on.

  7. #7
    Member Diumelia is offline
    MemberRank
    Apr 2009 Join Date
    BelgiumLocation
    60Posts

    Re: Total online script for offical website

    Quote Originally Posted by Organic View Post
    Dude, what the hell is wrong with you these days?
    Me? I just gave him a script to count rows..

  8. #8

    Re: Total online script for offical website

    Quote Originally Posted by DeadlyData View Post
    That's the hard way of going about it you could just use the CCU tables where it allows you to find out what cluster/etc they're all on.
    Hard way? Where the CCU tables are?
    and what's hard in 3 lines code? I tried to make it myself but i didn't know how to echo it



Advertisement