getElement('success', $tsAdmin->connect())) { #login as serveradmin $tsAdmin->login($ts3_user, $ts3_pass); #select teamspeakserver $tsAdmin->selectServer($ts3_port); #check if id parameter is set if(isset($_GET['id']) and !empty($_GET['id']) and ctype_digit($_GET['id'])) { #kick player from server if(!$tsAdmin->clientKick($_GET['id'], 'server')) { #show error if client kick was failed echo ''; } } #get clientlist $clients = $tsAdmin->clientList(); #print client count echo count($clients['data']) . ' clients on selected server

'; #print clients to browser foreach($clients['data'] as $client) { echo ''.$client['client_nickname'].'
'; } }else{ echo 'Connection could not be established.'; } /** * This code retuns all errors from the debugLog */ if(count($tsAdmin->getDebugLog()) > 0) { foreach($tsAdmin->getDebugLog() as $logEntry) { echo ''; } } ?>