iOS开发 判断扫码是否为有效网址
- (BOOL)achiveStringWithWeb:(NSString *)infor
{
NSString *emailRegex = @"[a-zA-z]+://.*";
NSPredicate *emailTest = [NSPredicate predicateWithFormat:@"SELF MATCHES %@", emailRegex];
return [emailTest evaluateWithObject:infor];
}