title: Sending Emoji's in push notifications in Parse on iOS
body: <p>I'm attempting to get Emoji's to show up in the push notifications sent out by parse, but the only thing I can get to show up in the notification is the utf-8 string (i.e. for police officer, I only see "\ud83d\udc6e").</p>
  
  <p>When I get the message on the device, and decode the string, the Emoji's come back and display just fine.</p>
  
  <p>On my server, I'm using Java, and receive the encoded string, then forward the data onto Parse.  The payload looks like:</p>
  
  <pre><code>"data":{"badge":"1","alert":"Crimson: \\ud83d\\udc6e\\ud83d\\ude21\\ud83d\\ude1a"
  </code></pre>
  
  <p>To build the Call to parse, I'm attempting to build a string with </p>
  
  <pre><code>data.put("alert", username + ": " + new String(message.getBytes(), "UTF-8"));
  </code></pre>
  
  <p>The push notification just shows "\ud83d\udc6e\ud83d\ude21\ud83d\ude1a"</p>
  
  <p>I can only assume I'm doing something wrong with the encoding/decoding of the text string as I'm passing it from iOS to my server, then back to Parse, but I can't for the life of me figure out what I'm doing wrong.</p>
  
  <p>For reference, here is the method I'm using to encode before sending:</p>
  
  <pre><code>NSString *uniText = [NSString stringWithUTF8String:[msg UTF8String]];
  NSData *msgData = [uniText dataUsingEncoding:NSNonLossyASCIIStringEncoding];
  NSString *encodevalue = [[NSString alloc] initWithData:msgData encoding:NSUTF8StringEncoding] ;
  </code></pre>
  
  <p>And for Decoding when received:</p>
  
  <pre><code>NSData *data = [msg dataUsingEncoding:NSUTF8StringEncoding];
  NSString *decodevalue = [[NSString alloc] initWithData:data encoding:NSNonLossyASCIIStringEncoding];
  </code></pre>
  
  <p>Thanks in advance for any help!</p>