iOS 开发实用技术导航
NSHipster 中文版
› http://nshipster.cn/
cocos2d 开源 2D 游戏引擎
› http://www.cocos2d-iphone.org/
CocoaPods
› http://cocoapods.org/
Google Analytics for Mobile 统计解决方案
› http://code.google.com/mobile/analytics/
WWDC
› https://developer.apple.com/wwdc/
Design Guides and Resources
› https://developer.apple.com/design/
Transcripts of WWDC sessions
› http://asciiwwdc.com
Cocoa with Love
› http://cocoawithlove.com/
Cocoa Dev Central
› http://cocoadevcentral.com/
NSHipster
› http://nshipster.com/
Style Guides
› Google Objective-C Style Guide
› NYTimes Objective-C Style Guide
Useful Tools and Services
› Charles Web Debugging Proxy
› Smore
lfflyers
V2EX  ›  iDev

iOS 上中文显示问题,有大神知道吗?

  •  
  •   lfflyers · Dec 7, 2016 · 4560 views
    This topic created in 3618 days ago, the information mentioned may be changed or developed.
    原字符串是“新建 MicrosoftPowerPoint 演示文稿”,然后展示的时候变成了“%E6%96%B0%E5%BB%BA%20Microsoft%20PowerPoint%20%E6%BC%94%E7%A4%BA%E6%96%87%E7%A8%BF ”,这是什么编码?怎么让它正常显示?
    10 replies  •  2016-12-08 14:14:20 +08:00
    lfflyers
    lfflyers
    OP
    Dec 7, 2016
    1
    自顶一下!
    ldp940622
    ldp940622
    Dec 7, 2016
    2
    Google iOS URL Decode
    ynyounuo
    ynyounuo
    Dec 7, 2016
    3
    URL Encoding
    lfflyers
    lfflyers
    OP
    Dec 7, 2016
    4
    @ldp940622 谢谢!
    ```objc
    NSString *encoded = @"fields=ID%2CdeviceToken";
    NSString *decoded = (__bridge_transfer NSString *)CFURLCreateStringByReplacingPercentEscapesUsingEncoding(NULL, (CFStringRef)encoded, CFSTR(""), kCFStringEncodingUTF8);
    NSLog(@"decodedString %@", decoded);
    ```
    lfflyers
    lfflyers
    OP
    Dec 7, 2016
    5
    @ynyounuo thank you!
    PEP4JASON
    PEP4JASON
    Dec 7, 2016
    6
    转一下码吧 这是 urlencode
    lfflyers
    lfflyers
    OP
    Dec 7, 2016
    7
    @PEP4JASON 嗯,谢谢了,问题解决了
    zengfxios
    zengfxios
    Dec 7, 2016
    8
    太弱了
    lfflyers
    lfflyers
    OP
    Dec 8, 2016
    10
    @zengfxios 哈哈,是的,太弱了
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   5289 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 36ms · UTC 06:16 · PVG 14:16 · LAX 22:16 · JFK 01:16
    ♥ Do have faith in what you're doing.