onLogin()
Availability:
Flash Player 6.0
SmartFoxServer Lite / Basic / Pro
Usage:
smartFox.onLogin(response)
Description:
The event is fired in response to a login() request.
Parameters:
The response object contains the following properties:| success | True if the login was successfull, False if login failed. The reason for failure is explained in the error parameter | |
| name | Your current nickname | |
| error | This parameter is passed only if login fails. It contains a server error message. |
Returns:
nothing
Example:
smartFox.onLogin = function(response)
{
if (response.success)
{
trace("Logged in as " + response.name)
}
else
{
trace("Could not login: " + response.error)
}
}
See also: