<?php
error_reporting(0);
if (empty($_GET["ip"])) {
$ip = 'play.spartacube.fr';
} else {
$ip = $_GET["ip"];
}
if (empty($_GET["port"])) {
$port = '25565';
} else {
$port = $_GET["port"];
}
$version = file_get_contents('http://api.serveurs-minecraft.com/api.php?Version_Ping&ip='.$ip.'&port='.$port.'');
$maxplayer = file_get_contents('http://api.serveurs-minecraft.com/api.php?Joueurs_Maximum_Ping&ip='.$ip.'&port='.$port.'');
$playeronline = file_get_contents('http://api.serveurs-minecraft.com/api.php?Joueurs_En_Ligne_Ping&ip='.$ip.'&port='.$port.'');
$MOTD = file_get_contents('http://api.serveurs-minecraft.com/api.php?Motd_Ping&ip='.$ip.'&port='.$port.'');
$favicon = file_get_contents('http://api.serveurs-minecraft.com/api.php?Favicon_Ping&ip='.$ip.'&port='.$port.'');
echo $version // Get version of the server
echo $maxplayer // Get slot(s) of the server
echo $playeronline // Get player(s) online of the server
echo $MOTD // Get MOTD of the server
echo $favicon // Get favicon of the server
?>
-
Notifications
You must be signed in to change notification settings - Fork 0
nathanlegroux/simple-mcserver-status
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Simply get minecraft servers informations !
Topics
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published