I'm trying to find how to extract "2013-05-01/game1" from "/games/usa/2013-05-01/game1.html", but I don't how to do that. I already tried some Regex on it but it didn't work. And I also don't know if this would be the best way. This is what I have tried so far.
NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:@"/[0-9]{4}-[0-9]{2}-[0-9]-{2}\//\.*$)" options:NSRegularExpressionCaseInsensitive error:NULL];
NSTextCheckingResult *newSearchString = [regex firstMatchInString:opening_time options:0 range:NSMakeRange(0, [opening_time length])];
NSString *substr = [opening_time substringWithRange:newSearchString.range];
NSLog(@"%@", substr);
Any help would be appreciated.