disconnect - Logging out of the client
XML request, sent by the client to the server
<protocol>
     <disconnect [sid="10"]/>
</protocol>
                    
XML response of the server to the client
<protocol>
    <response action="disconnect" errorCode="0" [sid="10"]/>
</protocol>
                    
XML message of the server to other clients
<protocol>
       <received action="disconnect" sentFrom="client1" [code="1"]/>
</protocol>
                        
Attribute
Meaning
sentFrom
Name of the client that logged out of the room.
code
1 - Disconnection of the client from the server in the case the XML Socket Multiuser Server is stopped or restarted.
2 - Disconnection of the client from the server in the case the number of logged users overpasses the allowed limit.
3 - Disconnection of the client in the case the memory used by the XML Socket Multiuser Server exceeds the value maxMemory.
4 - The client has been disconnected because of excessive size of the message sent to the XML Socket Multiuser Server. It was longer than the maximal allowed value maxMsgLength.
Note: Only the clients logged in the same room get the message as the unlogging client.

If the client has been disconnected from the server:
1. In the attribute sentFrom "server" is returned. The attribute is then returned in the shape sentFrom="server".
2. The parametr code is returned.