title: How to encode a URL in Swift
body: <p>This is my <code>URL</code>. </p>
  
  <p>The problem is, that the <code>address</code> field is not being appended to <code>urlpath</code>.</p>
  
  <p>Does anyone know why that is?</p>
  
  <pre><code>var address:string
  address = "American Tourister, Abids Road, Bogulkunta, Hyderabad, Andhra Pradesh, India"
  let urlpath = NSString(format: "http://maps.googleapis.com/maps/api/geocode/json?address="+"\(address)")
  </code></pre>