Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- - (void)viewDidLoad
- {
- [super viewDidLoad];
- [self setUrlAddress:@"http://google.com.pk"];
- // Do any additional setup after loading the view from its nib.
- NSURL *url = [NSURL URLWithString:self.urlAddress];
- //URL Requst Object
- NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
- //Load the request in the UIWebView.
- [self.webView setScalesPageToFit:YES];
- [self.webView loadRequest:requestObj];
- }
- - (void)webViewDidStartLoad:(UIWebView *)webView{
- [appDelegate showActivityView:self.view];
- }
- - (void)webViewDidFinishLoad:(UIWebView *)webView{
- [appDelegate hideActivityView];
- }
- NSString *currentURL = [webView stringByEvaluatingJavaScriptFromString:@"window.location.href"];
- NSSTRing * currentURL = webView.request.URL.absoluteString;
- - (void)viewDidLoad
- {
- [super viewDidLoad];
- NSString *urlAddress = [NSString stringWithFormat:@"http://www.google.com/pk];
- //Create a URL object.
- NSURL *url = [NSURL URLWithString:urlAddress];
- //URL Requst Object
- NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
- //Load the request in the UIWebView.
- [webView loadRequest:requestObj];
- }
- - (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement