title: Open web url link in browser in Swift
body: <p>I want to load webpage that link I fetched through web service. I have tried myself but result is not in favour.</p>
  
  <p>From server I was getting this kind of url:
  <a href="http://www.simrishamn.se/sv/kultur_fritid/osterlens_museum/" rel="noreferrer">http://www.simrishamn.se/sv/kultur_fritid/osterlens_museum/</a></p>
  
  <p>Also I have used this type of code to load the page:</p>
  
  <pre><code>let url = URL(string: "http://" + urlSting.addingPercentEncoding(withAllowedCharacters: .urlHostAllowed)!)
  UIApplication.shared.openURL(url!)
  </code></pre>
  
  <p>But when I test this code in device, its showing like this:</p>
  
  <p><a href="https://i.stack.imgur.com/LVbp0.png" rel="noreferrer"><img src="https://i.stack.imgur.com/LVbp0.png" alt="enter image description here"></a></p>
  
  <p>Please give some help to load fetched web url.</p>
  
  <p><strong>EDIT:</strong>
  After doing suggested changes, not web browser not opening though button click event is working, check below image for more clearance:</p>
  
  <p><a href="https://i.stack.imgur.com/VRF0c.png" rel="noreferrer"><img src="https://i.stack.imgur.com/VRF0c.png" alt="enter image description here"></a></p>