View Full Version : Viewer to display channel and its subchannels only
Hey guys...
Looking for a small script that would only shows the people in a channel, and its subchannels. I did see one on here that may work with cyts libs on PHP4, tried it but did not work. It was a longshot anyways since I am using PHP5.
As far as I know, PHP is downwardly compatible, so you can use this script with PHP 5 as well.
If you post the name of the script (or the script itsself would be better), we could help you a little bit more.
From the thread... http://forum.teamspeak.com/showthread.php?t=35750&highlight=display+channel
<?
include 'cyts.class.php';
/* init CyTS library */
$cyts = new cyts();
/* connect to TeamSpeak server */
$cyts->connect('localhost', 51234, 8767);
/* find a channel named Shoutbox */
$channel = $cyts->info_getChannelByName('Shoutbox'); //it's retur ID without get ['id]
/* create a new array containing players in channel Shoutbox */
$players = array();
foreach($cyts->info_playerList() as $player)
{
if($player['c_id'] == $channel)
{
$players[] = $player;
echo $player[15];
echo "<br>";
}
}
?>
CyTS is not a standard php library.
Did you install it on your system?
I have cyts.class.php in the root folder where I am trying to execute the script. Maybe I a missing something? I simply copied that above code and made the proper changes to chanlist.php. Executing it only gives a blank white page. Am I doing it wrong?
vBulletin® v3.7.3, Copyright ©2000-2009, Jelsoft Enterprises Ltd.