title: Swift iOS: How do I make an Instagram link?
body: <p>In my app, I want to have an image view that shows the current Instagram profile picture of the account (and will automatically update if the picture is changed), and when this <strong>image view is clicked, it links to the Instagram page.</strong></p>
  
  <p>Is using a UIImageView the correct way to go about this?  </p>
  
  <p>I set up an UIImageView as so...</p>
  
  <pre><code>class ViewController: UIViewController {
         var bgImage: UIImageView?
  
     override func viewDidLoad() {
      super.viewDidLoad()
  
      var image: UIImage = UIImage(named: "Example")!
      bgImage = UIImageView(image: image)
      bgImage!.frame = CGRectMake(0,0,100,200)
      self.view.addSubview(bgImage!)
     }
  }
  </code></pre>