1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

How To Get Online Players and Show That on Site

Discussion in 'Help' started by PocketMineSVMaker, Apr 6, 2020.

  1. ItsKuro

    ItsKuro Creeper

    Messages:
    3
    GitHub:
    ItsKuroMG
  2. NTT

    NTT Zombie

    Messages:
    311
    GitHub:
    NTT1906
    Dude, he want a plugin not a tip
     
  3. ItsKuro

    ItsKuro Creeper

    Messages:
    3
    GitHub:
    ItsKuroMG
    that is a plugin, dude
     
  4. NTT

    NTT Zombie

    Messages:
    311
    GitHub:
    NTT1906
    I don't said u
     
  5. GamakCZ

    GamakCZ Zombie Pigman

    Messages:
    598
    GitHub:
    GamakCZ
    Lmao he don't want plugin, he want a way to show player count on his website
     
  6. NTT

    NTT Zombie

    Messages:
    311
    GitHub:
    NTT1906
     
  7. ethaniccc

    ethaniccc Baby Zombie

    Messages:
    189
    GitHub:
    ethaniccc
    That's just a method he wants to use to query the server to show on a website.
     
  8. GamakCZ

    GamakCZ Zombie Pigman

    Messages:
    598
    GitHub:
    GamakCZ
    It's useless to write plugin while you can use queryapi for that
     
    NTT and ethaniccc like this.
  9. NTT

    NTT Zombie

    Messages:
    311
    GitHub:
    NTT1906
    Anyway i made one so, do u want to get it?
    Also thank everyone for helping me know more information about MySQL, thanks all
     
  10. PocketMineSVMaker

    PocketMineSVMaker Silverfish

    Messages:
    21
    Yes Please, @NTT
     
  11. NTT

    NTT Zombie

    Messages:
    311
    GitHub:
    NTT1906
  12. PocketMineSVMaker

    PocketMineSVMaker Silverfish

    Messages:
    21
  13. GodWeedZao

    GodWeedZao Zombie Pigman

    Messages:
    401
    GitHub:
    godweedzao
    its wrong some times, use getOnlinePlayers() instead.
     
  14. GodWeedZao

    GodWeedZao Zombie Pigman

    Messages:
    401
    GitHub:
    godweedzao
  15. ethaniccc

    ethaniccc Baby Zombie

    Messages:
    189
    GitHub:
    ethaniccc
    If the website is able to use PHP, you can use some things like libpmquery and use it to get the amount of players on your server.

    An example:
    PHP:
    <?php

    require 'The_file_path_to_libpmquery';
    require 
    'The_file_path_to_libpmqueryexception';

    try{

        
    $data PMQuery::query("params");
        echo 
    '<p>' $data["Players"] . '</p>';
        
    } catch(
    PmQueryException $e){
        echo 
    "<p>Something went wrong!</p>";
    }
     
  16. NTT

    NTT Zombie

    Messages:
    311
    GitHub:
    NTT1906
    Yeah, i got busy that time so i didn't notice that. Thank you!
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.