ios - AFNetworking 在多语言应用程序中崩溃
<p><blockquote>
<p>Ride=2152,%20Mohali%20Stadium%20Rd,%20Phase%2010,%20Sector%2064,%20Sahibzada%20Ajit%20Singh%20Nagar,%20Punjab%20160062,%20भारत</p>
</blockquote>
<p>此参数在以印地语运行时导致崩溃,而在西类牙语和英语下运行良好。请建议我。崩溃描述如下:-</p>
<blockquote>
<p>*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Invalid parameter not
satisfying: URLString'</p>
<hr/>
</blockquote></p>
<br><hr><h1><strong>Best Answer-推荐答案</ strong></h1><br>
<p><p>检查一下</p>
<p><strong>目标 - C</strong></p>
<pre><code>NSString *string = @"भारत";
NSString *encoded = ];
</code></pre>
<p><strong>Swift 3.0</strong></p>
<pre><code>let string = "भारत"
let urlString = string.addingPercentEncoding( withAllowedCharacters: . urlUserAllowed)
</code></pre>
<blockquote>
<p>Output :: %E0%A4%AD%E0%A4%BE%E0%A4%B0%E0%A4%A4</p>
</blockquote></p>
<p style="font-size: 20px;">关于ios - AFNetworking 在多语言应用程序中崩溃,我们在Stack Overflow上找到一个类似的问题:
<a href="https://stackoverflow.com/questions/44023064/" rel="noreferrer noopener nofollow" style="color: red;">
https://stackoverflow.com/questions/44023064/
</a>
</p>
页:
[1]