我有这段代码:
if (email.text == emailComfirm.text) {
UIAlertView *emailAllertView = [[UIAlertView alloc] initWithTitle:@"Succes" message:@"Yaaay, je kan nu gebuik gaan maken van Vogelspotter." delegate:self cancelButtonTitle:@"Direct aanmelden" otherButtonTitles: nil];
[emailAllertView show];
// Doing some other code here
[self dismissModalViewControllerAnimated:YES];
}else{
NSLog(@"email: %@", email.text);
NSLog(@"email: %@", emailComfirm.text);
UIAlertView *emailAllertView = [[UIAlertView alloc] initWithTitle:@"Foutmelding" message:@"De opgegeven email adressen komen niet met alkaar overeen" delegate:self cancelButtonTitle:@"Probeer het nog eens" otherButtonTitles: nil];
[emailAllertView show];
}
不知何故,我没有输入文本字段,如果我输入 ee/ee 或 ee/ff,is 语句总是转到 else。有人可以告诉我我做错了什么吗?
tnx 提前。