```
+ (NSArray*)filterImage:(NSString*)html{
NSMutableArray *resultArray = [NSMutableArray array];
NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:@"<(img|IMG)(.*?)(/>|></img>|>)" options:NSRegularExpressionAllowCommentsAndWhitespace error:nil];
NSArray*result = [regexmatchesInString:htmloptions:NSMatchingReportCompletionrange:NSMakeRange(0, html.length)];
for(NSTextCheckingResult*iteminresult) {
NSString*imgHtml = [htmlsubstringWithRange:[itemrangeAtIndex:0]];
NSArray*tmpArray =nil;
if([imgHtmlrangeOfString:@"src=\""].location!=NSNotFound) {
tmpArray = [imgHtmlcomponentsSeparatedByString:@"src=\""];
}elseif([imgHtmlrangeOfString:@"src="].location!=NSNotFound) {
tmpArray = [imgHtmlcomponentsSeparatedByString:@"src="];
}
if(tmpArray.count>=2) {
NSString*src = tmpArray[1];
NSUIntegerloc = [srcrangeOfString:@"\""].location;
if(loc !=NSNotFound) {
src = [srcsubstringToIndex:loc];
[resultArrayaddObject:src];
}
}
}
returnresultArray;
}
```