Register for your free account! | Forgot your password?

Go Back   elitepvpers > Other Online Games > Minecraft
You last visited: Today at 20:52

  • Please register to post and access all features, it's quick, easy and FREE!

 

[PHP]Server-Status

Reply
 
Old   #16

 
elite*gold: 5971
Join Date: May 2011
Posts: 2,803
Received Thanks: 8,461
Sieht ganz gut aus schatzi
:P
#thx given#



nybu is offline  
Old   #17
 
elite*gold: 0
Join Date: Sep 2011
Posts: 77
Received Thanks: 5
Naja son plugin wär doch auch nice ^^ , meld dich mal skype


xXx_Chrisi_xXx is offline  
Old   #18
 
elite*gold: 0
Join Date: Feb 2011
Posts: 10
Received Thanks: 2
PHP Code:
<title>ServerStatus</title>
<?php
$host 
"85.214.24.133";
$port 25565;

$socket socket_create(AF_INETSOCK_STREAMSOL_TCP);
$connected socket_connect($socket$host$port);
if (
$connected) {
    
$ping_start microtime(true);
    
socket_send($socket"\xFE"10);
    
$data "";
    
$result socket_recv($socket, &$data500);$ping_end microtime(true);
    
socket_close($socket);

    if (
$result != false && substr($data01) == "\xFF") {
        
$info explode("\xA7"mb_convert_encoding(substr($data,1), "iso-8859-1""utf-16be"));
        
$serverName substr($info[0], 1);
        
$playersOnline $info[1];
        
$playersMax $info[2];
        
$ping round(($ping_end $ping_start) * 1000);
        echo     
"Server: $serverName<br/>
                Address: 
$host<br/>
                Port: 
$port<br/>
                Players Online: 
$playersOnline/$playersMax <br/>
                Ping: 
$ping ms<br/>";
    } else {
        echo 
"Failed to receive data";
    }
} else {
    echo 
"Failed to connect";

?>
ISt aus dem Bukkit Forum
hier eine Preview

funktioniert auch mit dem Vanilla Server
Suchty112 is offline  
Thanks
1 User
Old   #19
 
elite*gold: 25
Join Date: Jul 2008
Posts: 423
Received Thanks: 28
Quote:
Originally Posted by Suchty112 View Post
PHP Code:
<title>ServerStatus</title>
<?php
$host 
"85.214.24.133";
$port 25565;

$socket socket_create(AF_INETSOCK_STREAMSOL_TCP);
$connected socket_connect($socket$host$port);
if (
$connected) {
    
$ping_start microtime(true);
    
socket_send($socket"\xFE"10);
    
$data "";
    
$result socket_recv($socket, &$data500);$ping_end microtime(true);
    
socket_close($socket);

    if (
$result != false && substr($data01) == "\xFF") {
        
$info explode("\xA7"mb_convert_encoding(substr($data,1), "iso-8859-1""utf-16be"));
        
$serverName substr($info[0], 1);
        
$playersOnline $info[1];
        
$playersMax $info[2];
        
$ping round(($ping_end $ping_start) * 1000);
        echo     
"Server: $serverName<br/>
                Address: 
$host<br/>
                Port: 
$port<br/>
                Players Online: 
$playersOnline/$playersMax <br/>
                Ping: 
$ping ms<br/>";
    } else {
        echo 
"Failed to receive data";
    }
} else {
    echo 
"Failed to connect";

?>
ISt aus dem Bukkit Forum
hier eine Preview

funktioniert auch mit dem Vanilla Server
danke hilft für die useranzahl usw

€dit: scheint alles zu funktionieren bis auf players online wäre nett wenn du mir link zum Post per PN schickst damit ich mir das genau ansehn kann.


DerSaboteur is offline  
Reply



« Previous Thread | Next Thread »

Similar Threads
Reg Page Edited Server Status + Extra Status
This is a new realease of the reg page created by Xsense Download XAMP apache friends - xampp for windows Reg Page Files (By Tazdingo And...
22 Replies - SRO Coding Corner
[Server Status] Server Status Programs From A Couple Servers.
Hey i dont know in what section to post it so i hope that the mods will move it to the good section but i made this server status program i will make...
9 Replies - CO2 Main - Discussions / Questions



All times are GMT +1. The time now is 20:52.


Powered by vBulletin®
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Abuse
Copyright ©2018 elitepvpers All Rights Reserved.