作者:lixinglon257 | 来源:互联网 | 2023-01-30 14:44
在info.plist里面添加如下内容即可:
<key>NSAppTransportSecuritykey>
<dict>
<key>NSAllowsArbitraryLoadskey>
<true/>
dict>
========
"1.0" encoding="UTF-8"?>
"-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
version="1.0">
CFBundleDevelopmentRegion
en
CFBundleExecutable
$(EXECUTABLE_NAME)
CFBundleIdentifier
$(PRODUCT_BUNDLE_IDENTIFIER)
CFBundleInfoDictionaryVersion
6.0
CFBundleName
$(PRODUCT_NAME)
CFBundlePackageType
APPL
CFBundleShortVersionString
1.0
CFBundleSignature
????
CFBundleVersion
1
LSRequiresIPhoneOS
UIRequiredDeviceCapabilities
armv7
UIStatusBarHidden
UISupportedInterfaceOrientations
UIInterfaceOrientationPortrait
NSAppTransportSecurity
NSAllowsArbitraryLoads