I am developing a form where the user needs to enter a valid email. He/she will use it as a loginid to play the game.I want to know how can I validate the username containing @, similar to string.contains function. I learnt we can use string.indexOf() but it is not supporting "@". Kindly suggest how do I carry out this validation. When the email editfield loses focus, the username must be checked to see if it contains "@" or not.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…