Objective C - RegexKitLite - Parsing inner contents of a string, ie: start(.*?)end
- by Stu
Please consider the following:
NSString *myText = @"mary had a little lamb";
NSString *regexString = @"mary(.*?)little";
for)NSString *match in [myText captureComponentsMatchedByRegex:regexString]){
NSLog(@"%@",match);
}
This will output to the console two things:
1) "mary had a little"
2) "had a"
What I want is just the 2nd bit of…