Skip to content

Instantly share code, notes, and snippets.

@CloudyWater
Created January 31, 2017 00:40
Show Gist options
  • Save CloudyWater/558e1df65ac947c6f479fda242228b81 to your computer and use it in GitHub Desktop.
Save CloudyWater/558e1df65ac947c6f479fda242228b81 to your computer and use it in GitHub Desktop.
Update to the PostLoginAccount() function
IEnumerator PostLoginAccount (string username, string password)
{
string postUrl = GET_USER_URL + "username=" + WWW.EscapeURL (username) + "&password=" +
WWW.EscapeURL(Crypto.Encrypt(password));
WWW hsPost = new WWW (postUrl);
yield return hsPost;
if (hsPost.error != null)
{
Debug.Log ("Error: " + hsPost.error);
}
else
{
if (hsPost.text.Contains ("Verified"))
{
Debug.Log ("Successful login");
}
else
{
Debug.Log (hsPost.text);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment