Saturday, February 5, 2011

iPhone Application

Hello, I want to integrate some links on my iphone application. That is when user touch on the button say "Yahoo" then Yahoo's page will be opened and then all the functionalities of Yahoo mail has proceeds. How can I do that? I have a bit idea about NSURL, but not much. Please help me for that. Thanks in advance..

  • In the action method of the target put something like:

     [[UIApplication sharedApplication] openURL:[NSURL URLWithString: @"http://www.google.com"]];
    
    lostInTransit : To come back to ur application, you will have to tap on the app's icon in springboard. If you want to stay within the app and open the URL, use a UIWebView instead
    From HyLian
  • To open the page in Mobile Safari, you need to implement something like the following:

    NSURL *url = [NSUR URLWithString:@"http://www.google.com"];
    [[UIApplication sharedApplication] openURL:url];
    

    You could return to your application using Custom URL Schemes (for more information see the iPhone Application Programming Guide), but since you want to access sites over which you have no control, I presume that isn't an option? Could you use a UIWebView control within your app instead?

    From Edd

0 comments:

Post a Comment