I have json string from here: http://vkontakte.ru/al_video.php?act=load_videos_silent&al=1&oid=8046830
I use Touch json parser.
//received json string from ASIHTTPRequest
NSString *responseString = [request responseString];
//removing all html elements like "br"
NSString *jsonString = [self decodeHTMLEntities:responseString];
//remove 4830<!><!>0<!>4316<!>0<!> this string at the beginning
jsonString = [jsonString stringByReplacingCharactersInRange:NSMakeRange(0, 25) withString:@""];
NSArray *arr = [jsonString JSONValue]
//And here is an error in Debug console: -JSONValue failed. Error is: Illegal start of token [']
How to solve this?
I think you have to replace all the ‘ by “. JSON usually doesn’t support ‘ as a token delimitor.
use :