title: Encoding Issue apending NSData to Post
body: <p>I have got problem uploading a file to a server through POST</p>
  
  <p>I build the request body by loading a html file and inserting the data:</p>
  
  <pre><code>------WebKitFormBoundaryMAsmIFCr12izlsoH
  Content-Disposition: form-data; name="token"
  
  %@
  ------WebKitFormBoundaryMAsmIFCr12izlsoH
  Content-Disposition: form-data; name="userfile"; filename="%@"
  Content-Type: AES256/encrypted
  
  %@
  ------WebKitFormBoundaryMAsmIFCr12izlsoH--
  Content-Disposition: form-data; name="submit"
  
  Datei absenden
  ------WebKitFormBoundaryMAsmIFCr12izlsoH--
  </code></pre>
  
  <p>But to insert the the data fia string with format, it must be a string. So I alloc initWithData:data encoding NSASCIIStringEncoding cause the data can not be displayed in UTF8. The rest of the request is in UTF8, so afterwards if need dataUsingEncoding:NSUTF8StringEncoding. This breaks the data. There some bytes on the wrong place and so on. So I tried an other way, I spitted the html into two parts, and made a sandwich of it. html, data, html Unfortunately the request now looks like the second html is part of the file, so the file is broken again. 
  Do you know a better method?
  Thanks in advance,
  Jannes</p>