title: NSData isn't encoding image into Base64 string properly
body: <p>I am using following simple code to convert Image to Base64 string in iOS</p>
  
  <pre><code>NSData *originalPhoto = UIImagePNGRepresentation([UIImage imageNamed:@"Time_Icon.png"]);
  NSString *base64PhotoString = [originalPhoto base64EncodedStringWithOptions:0];
  </code></pre>
  
  <p>When i try to decode the string in base64PhotoString variable using one of the online Base64 image decode service image doesn't get reproduced, not sure whats going wrong. I am sending this string to a service there also image doesn't get recognised.</p>
  
  <p>ok tried playing with the options and finally could get the image encoded which gets decoded using online tools properly , but still its not recognised on server side , server side programmer is using <a href="http://www.newtonsoft.com/json/help/html/Methods_T_Newtonsoft_Json_JsonSerializer.htm" rel="nofollow">http://www.newtonsoft.com/json/help/html/Methods_T_Newtonsoft_Json_JsonSerializer.htm</a> 
  this library to deserialise the JSON having image in it to object , it simply ignores the image , I am using RestKit to call server side , what i have realised is RestKit added escape characters to encoded image data , can that be a problem ? </p>