UIWebView URL custom

Discussion in 'iOS Development' started by JoshuaCaputo, Jan 24, 2009.

  1. JoshuaCaputo

    JoshuaCaputo New Member

    Joined:
    Aug 2, 2008
    Messages:
    605
    Likes Received:
    0
    Device:
    iPod touch
    What i want to do is have a text field and than u enter a URL and the webview goes there.

    Code:
    NSString *enteredURL = "ifans.com";
    
    Code:
    	[card loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:@"http://"+[COLOR="Lime"]enteredURL[/COLOR]]]];
    
  2. bddckr

    bddckr Active Member

    Joined:
    Dec 2, 2007
    Messages:
    1,434
    Likes Received:
    18
    Device:
    iPhone 4 (Black)
    Code:
    	[card loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"http://%@", enteredURL]]]];
    
  3. JoshuaCaputo

    JoshuaCaputo New Member

    Joined:
    Aug 2, 2008
    Messages:
    605
    Likes Received:
    0
    Device:
    iPod touch
    got it thanks

Share This Page