ios webView在加载html的时候,怎么传参数?

解决 办法
将参数拼接到url上 用

NSURL *url = [NSURL URLWithString:[[NSString stringWithFormat:@“拼接参数“] stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding] relativeToURL:[NSURL URLWithString:path]];//path是路径
[self.webView loadRequest:[NSURLRequest requestWithURL:url cachePolicy:NSURLRequestUseProtocolCachePolicy timeoutInterval:20.f]];

猜你喜欢

转载自blog.csdn.net/u013983033/article/details/83825865