HTTP请求url中文转码

  NSString *urlStr = [NSString stringWithFormat:@"userName=&psw="];
    urlStr = [urlStr stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLUserAllowedCharacterSet];
]];

 

posted @ 2016-05-27 12:38  aRenOuBa  阅读(3101)  评论(0编辑  收藏  举报