You have to tokenize the player's chat before you check
tokens[0]—otherwise, the array doesn't exist yet.
PHP Code:
//#CLIENTSIDE
function onPlayerChats() {
temp.tokens = player.chat.tokenize();
if(tokens[0] == "/kill") {
triggerServer("gui", this.name, tokens);
}
}