How to use uiwebview to show some web page?

2019-06-24 06:23发布

问题:

How to use uiwebview to show some web page for url request? i dont know how to do it. who can tell me how to do it? has any opensource? thanks.

回答1:

NSString *urlAddress = @"http://www.google.com";
NSURL *url = [NSURL URLWithString:urlAddress];
NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
[webView loadRequest:requestObj];