ctaodream
V2EX  ›  问与答

不做任何配置 iOS 好像现在又能访问 http 开头的网络

  •  
  •   ctaodream · Sep 23, 2016 · 2500 views
    This topic created in 3698 days ago, the information mentioned may be changed or developed.
    2 replies  •  2016-09-26 16:38:17 +08:00
    Vernsu
    Vernsu
    Sep 23, 2016
    1
    举例子
    ctaodream
    ctaodream
    OP
    Sep 26, 2016
    2
    适配 iOS9 的时候 如果 APP 的服务端还没有开启 https ,通常我们需要在 info.plist 中加入
    NSAllowsArbitraryLoads = YES,不然的话访问 http 会报错 不能成功 ,但现在不配合这个 key ,或者
    NSAllowsArbitraryLoads = NO 也可以开始访问了
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1658 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 87ms · UTC 08:23 · PVG 16:23 · LAX 00:23 · JFK 03:23
    ♥ Do have faith in what you're doing.