@H_
404_0@- (BOOL)checkPhoneNum{
return [_phoneNum.text isMatchedByRegex:@"^(13[0-9]|15[0-9]|18[0-9])\\d{8}$"];
}
- (void)nextClick{
if (![self checkPhoneNum]) {
UIAlertView * alert = [[UIAlertView alloc] initWithTitle:@"
提示" message:@"您输入的手机号格式不正确" delegate:self cancelButtonTitle:nil otherButtonTitles:@"确定",nil];
[alert show];
return;
}
}- (BOOL)checkEmail { return [_mainEmail.text isMatchedByRegex:@"\\b([a-zA-Z0-9%_.+\\-]+)@([a-zA-Z0-9.\\-]+?\\.[a-zA-Z]{2,6})\\b"]; } - (BOOL)checkUrl { return [_mainUrl.text isMatchedByRegex:@"\\bhttps?://[a-zA-Z0-9\\-.]+(?::(\\d+))?(?:(?:/[a-zA-Z0-9\\-._?,'+\\&%$=~*!():@\\\\]*)+)?"]; }