channel creator script for ts-website

Asphyxia

Server Monkey
Administrator
Joined
Apr 25, 2015
Messages
1,292
Points
252
Age
26
Location
North America
creating channels on the site like this
Can you elaborate to us what "like this" means?

Please realize that if someone has to read your post, then go be tasked onto a mission/job like go to this site, connect to a server, click buttons.. etc.

It's like asking someone to do free work ;)

Please give information in your post/request so we know what you REALLY want to do and we can help you easier and faster.
 

marlen9797

Member
Joined
Aug 18, 2018
Messages
9
Points
33
Age
22
Location
Moscow, Russia

Can you elaborate to us what "like this" means?

Please realize that if someone has to read your post, then go be tasked onto a mission/job like go to this site, connect to a server, click buttons.. etc.

It's like asking someone to do free work ;)

Please give information in your post/request so we know what you REALLY want to do and we can help you easier and faster.

Channel creator like this screen
 

Asphyxia

Server Monkey
Administrator
Joined
Apr 25, 2015
Messages
1,292
Points
252
Age
26
Location
North America
permanent channels with icon (PHP)
I will toss a snippet at you real quick.

Go here: https://docs.planetteamspeak.com/ts3/php/framework/

Features of the TS3 PHP Framework include:
Fully object-oriented PHP 5 and E_STRICT compliant components
Access to all TeamSpeak 3 Server features via ServerQuery
Integrated full featured and customizable TSViewer interfaces
Full support for file transfers to up- and /or download custom icons and other stuff
Powerful error handling capabilities using exceptions and customizable error messages
Dynamic signal slots for event based scripting

Code:
// load framework files
require_once("libraries/TeamSpeak3/TeamSpeak3.php");
// connect to local server, authenticate and spawn an object for the virtual server on port 9987
$ts3_VirtualServer = TeamSpeak3::factory("serverquery://username:[email protected]:10011/?server_port=9987");
// create a top-level channel and get its ID
$top_cid = $ts3_VirtualServer->channelCreate(array(
"channel_name" => "My Channel",
"channel_topic" => "This is a top-level channel",
"channel_codec" => TeamSpeak3::CODEC_SPEEX_WIDEBAND,
"channel_flag_permanent" => TRUE,
));
// create a sub-level channel and get its ID
$sub_cid = $ts3_VirtualServer->channelCreate(array(
"channel_name" => "My Sub-Channel",
"channel_topic" => "This is a sub-level channel",
"channel_codec" => TeamSpeak3::CODEC_SPEEX_NARROWBAND,
"channel_flag_permanent" => TRUE,
"cpid" => $top_cid,
));
It is pretty much all done for you, get the TS3 PHP framework, toss in the snippet.. make some modifications and put that into a loop?

Do you know anything about PHP programming or no.. you may want to reference https://www.php.net/manual/en/control-structures.for.php for how to setup loops.

But basically you are going to configure/setup the TS3 PHP framework appropriately to your/the server. Then you will be able to flood, but keep in mind you will likely need to have access to server admin of sorts because the anti-flooding or anti-spam for TeamSpeak prohibits mass flooding of channel creation, plus I think default permissions only allow permanent channels to permissioned users.

I could set this all up for you, but for something so simple as just a channel creator - this already does it. You just have to set it up. :)
 
Last edited:

wNt

Member
Joined
Apr 13, 2016
Messages
4
Points
35
Age
27
Fatal error: Uncaught Error: Call to a member function bind_param() on boolean in /var/www/html/test/src/room/index.php:220 Stack trace: #0 {main} thrown in /var/www/html/test/src/room/index.php on line 220

how can fix it the error?
 

Asphyxia

Server Monkey
Administrator
Joined
Apr 25, 2015
Messages
1,292
Points
252
Age
26
Location
North America
It is a pretty nice script/site he put together but I notice one inefficiency.

https://ts.wruczek.tech/viewer.php as you click between ban list, and other pages - you will notice the ENTIRE page reloads.

He should use https://ts.wruczek.tech/#banlist and similar to influence a JavaScript response (AJAX) to trigger a clean refresh of the main content div to the left. The way each script is called direct as a separate ".php" file could be improved.

I am curious to see how others develop a similar project.
 

Ondra3211

Contributor
Joined
May 5, 2018
Messages
56
Points
51
Location
Czech Republic
Sorry but I cant reproduce the issue.
Everything works fine on my side.
PHP 7.3.7
PHP 7.3.7
Code:
Fatal error: Uncaught TeamSpeak3_Adapter_ServerQuery_Exception: invalid parameter in /var/www/ts/test/src/TeamSpeak3/Adapter/ServerQuery/Reply.php:316 Stack trace: #0 /var/www/ts/test/src/TeamSpeak3/Adapter/ServerQuery/Reply.php(88): TeamSpeak3_Adapter_ServerQuery_Reply->fetchError(Object(TeamSpeak3_Helper_String)) #1 /var/www/ts/test/src/TeamSpeak3/Adapter/ServerQuery.php(140): TeamSpeak3_Adapter_ServerQuery_Reply->__construct(Array, 'channelcreate c...', Object(TeamSpeak3_Node_Host), true) #2 /var/www/ts/test/src/TeamSpeak3/Node/Abstract.php(70): TeamSpeak3_Adapter_ServerQuery->request('channelcreate c...', true) #3 /var/www/ts/test/src/TeamSpeak3/Node/Server.php(87): TeamSpeak3_Node_Abstract->request('channelcreate c...', true) #4 /var/www/ts/test/src/TeamSpeak3/Node/Abstract.php(94): TeamSpeak3_Node_Server->request('channelcreate c...') #5 /var/www/ts/test/src/TeamSpeak3/Node/Server.php(150): TeamSpeak3_Node_Abstract->execute('channelcreate', Array) #6 /var/www/ts/test/index.php(42): TeamSpeak3_Node_Server->channelCre in /var/www/ts/test/src/TeamSpeak3/Adapter/ServerQuery/Reply.php on line 316
 

Top