Hello,
I've coded a simple php kick request by a telnet connection It will send a message to the character who's being kicked, wait for 4 second then kick him.
Code:
<?php
$Server = 'your_host.com';
$Port = 9000;
$user = "user\r";
$pass = "pass\r";
$kickedchar = $_POST['kickedchar'];
$message = $_POST['message'];
$fp = fsockopen($Server, $Port);
fputs ($fp, $user);
//echo("Login Accepted\r\n");
usleep(125000);
fputs ($fp, $pass);
usleep(125000);
//echo("Password Accepted\r\n");
fputs($fp, "tell $kickedchar $message\r");
sleep(4);
fclose($fp);
$fp = fsockopen($Server, $Port);
fputs ($fp, $user);
//echo("Login Accepted\r\n");
usleep(125000);
fputs ($fp, $pass);
usleep(125000);
fputs($fp, "kick $kickedchar\r");
echo("$kickedchar has been kicked out!");
fclose($fp);
?>
and the html..
Code:
<HTML>
<BODY>
<FORM METHOD="post" ACTION="kick_char.php">
Character Name : <INPUT TYPE="text" SIZE="20" NAME="kickedchar"><BR>
Message to say : <INPUT TYPE="text" SIZE="60" NAME="message"><BR>
<INPUT TYPE="submit" VALUE="Envoyer" NAME="valider">
</FORM>
</BODY>
</HTML>
I'm actually working on a Php-portal with the important GM features to admin the server. I think that could help.
Mag