protected function login() { $this->state = self::CONN_STATE_LOGIN_PACKET_SENT; $this->write("Action: login\r\n" . "Username: " . $this->username . "\r\n" . "Secret: " . $this->secret . "\r\n" . "Events: on\r\n" . "\r\n"); }