API
You can use a server list API for show server info in the website.
You need to add this code to your website:
<?php $server = json_decode(file_get_contents("https://teamspeak3-servers.eu/server/<server_ip:port>/api.json"), false); ?>
And now you can use a server info data:
<?php echo $server->clients; //show count on-line clients ?>
You can use variables:
$server->ip_address | show server ip address (without port) |
$server->port | show server port |
$server->clients | show count on-line clients |
$server->clients_max | show count max clients |
$server->ping | show server ping |
$server->status | show server status |
$server->uptime | show server uptime |
$server->name | show server name |
and more next..