Skip to content

Instantly share code, notes, and snippets.

@iscott
Created August 7, 2014 03:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save iscott/e88616c9c0f1422e1ae3 to your computer and use it in GitHub Desktop.
Save iscott/e88616c9c0f1422e1ae3 to your computer and use it in GitHub Desktop.
Web Wrapper App
import UIKit
class ViewController: UIViewController {
@IBOutlet var webView: UIWebView!
@IBAction func goBack(sender: AnyObject) {
webView.goBack()
}
@IBAction func goForward(sender: AnyObject) {
webView.goForward()
}
override func viewDidLoad() {
super.viewDidLoad()
let url = NSURL(string: "http://google.com")
let request = NSURLRequest(URL: url)
webView.loadRequest(request)
}
override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment