NSString *htmlSource = [NSString stringWithContentsOfURL:[NSURL URLWithString:urlString] encoding:0x80000000 + kCFStringEncodingDOSKorean error:nil];
NSLog(htmlSource);
I get html result tag like (col width="16"/)~~~ but the real html tag is (col width="16%"/)
% character disappears. what is problem?
The string might still contain a %
; NSLog()
itself gives special significance to a %
sign (consider what happens if you use %@
, %d
, etc.).
Try doing this: NSLog(@"%@", htmlSource)
; that will log only an object (the string) and keep it out of the formatting argument.
User contributions licensed under CC BY-SA 3.0