Resource icon

Advert | SCRIPT 1.6

No permission to download

iKaros

Restricted
Oct 4, 2017
87
40
34
iKaros submitted a new resource:

Advert | SCRIPT - Give your server another look with this wonder.

Preview:

Coming soon...


Code:
Code:
<?PHP
/**
  * Teamspeak3_Advert.php
  *
  * Is a small script that sends a message in the Serverchat every x seconds.
  *
  * by iKaros - <[email protected]> with the ts3admin.class framework <http://ts3admin.info/>
  *
*/

/*-------SETTINGS-------*/
$ts3_ip = '127.0.0.1';
$ts3_queryport = 10011;
$ts3_user = 'username';
$ts3_pass = 'password';
$ts3_port = 9987;
/*----------------------*/
    
$xyz = 1...

Read more about this resource...
 

0x03D4D5

Active Member
Oct 13, 2015
21
13
75
not going to flame you but ..

"This script can not be sold, or any other type of income obtained without the exclusive permission of its own author (iKaros)."
Your script is the most basic script of sending a message to a server. Pretty much everyone who ever starts using the ts3class will do the same lines of code as you did ..

besides a few lines that are not optimized at all ..
Code:
1. You are creating the object every X seconds instead of creating it once and let it loop

2. Your comments and namings are mostly useless:
#Message to send. # we already know this is the message that gets sent to the selected server
$messageToSend = "...";
-----------------------------------
#login as serveradmin # using serveradmin to login is a security flaw. clever dudes have their own query login to handle what they want to do for different scripts.
$tsAdmin->login($ts3_user, $ts3_pass);

3. Unusual coding such as ..
$xyz = 1;
while($xyz == 1) # why do we need to define a variable to have a infinite loop? a simple while(true) or a explicit version would be while(true == true) is enough and would take less lines of code.

I am not sure how experienced you are in coding/scripting in PHP but based on what you said about "This script can not be sold" I expect a much higher quality code.
Again, Am not flaming nor disrespecting you. Just giving you some advices and what can be improved before even thinking about what if someone wants to sell your code.

greets
 
Top