2016-04-07 13 views
0
[_webView loadData:[objEventDetail.eventdesc dataUsingEncoding:NSUTF8StringEncoding] MIMEType:@"text/html" textEncodingName:@"" baseURL:[NSURL URLWithString:@""]]; 

Dies ist der HTML-StringWie werden Emojis in der Webansicht in iOS 9 angezeigt?

<p style="margin: 0px 0px 6px; color: rgb(20, 24, 35); font-family: helvetica, arial, sans-serif; font-size: 14px; line-height: 19.32px; background-color: rgb(255, 255, 255);">Team Unstoppable has got your back<em style="background-image:url(&quot;/rsrc.php/v2/yp/r/aeO1ik7i7-T.png&quot;); background-position:0px -5950px; background-repeat:no-repeat; background-size:auto; display:inline-block; height:16px; vertical-align:-3px; width:16px"></em><em style="background-image:url(&quot;/rsrc.php/v2/yp/r/aeO1ik7i7-T.png&quot;); background-position:0px -5950px; background-repeat:no-repeat; background-size:auto; display:inline-block; height:16px; vertical-align:-3px; width:16px"></em></p> 

<p style="margin: 6px 0px; color: rgb(20, 24, 35); font-family: helvetica, arial, sans-serif; font-size: 14px; line-height: 19.32px; background-color: rgb(255, 255, 255);">On Friday 22nd April, we invite you to Club 51 Degrees to celebrate the birthday  of one of Dancehall&#39;s heavy hitters.</p> 

<p style="margin: 6px 0px; color: rgb(20, 24, 35); font-family: helvetica, arial, sans-serif; font-size: 14px; line-height: 19.32px; background-color: rgb(255, 255, 255);">All the way from Jamaica&nbsp;<em style="background-image:url(&quot;/rsrc.php/v2/yp/r/aeO1ik7i7-T.png&quot;); background-position:0px -2839px; background-repeat:no-repeat; background-size:auto; display:inline-block; height:16px; vertical-align:-3px; width:16px"></em><em style="background-image:url(&quot;/rsrc.php/v2/yp/r/aeO1ik7i7-T.png&quot;); background-position:0px -2839px; background-repeat:no-repeat; background-size:auto; display:inline-block; height:16px; vertical-align:-3px; width:16px"></em>CHARLY BLACK!!!!</p> 

<p style="margin: 0px 0px 6px;">We got Trinidad  &amp; Jamaica  lined up +<br /> 
Guest artistes :<br /> 
-Press Kay<br /> 
-Pretti Kiiti<br /> 
-Shurwayne Winchester<br /> 
-5 Star Akil</p> 

<p style="margin: 6px 0px;">Guest DJ -<br /> 
~ZJ Johnny Kool from Jamaica&#39;s Zip 103fm</p> 

<p style="margin: 6px 0px;">Also on the roster for this birthday bash:</p> 

<p style="margin: 6px 0px;">&bull;Custodian Int&#39;l<br /> 
&bull;Rapid Response<br /> 
&bull;Trevlyn the Voice<br /> 
&bull;Hollywood Sachy</p> 

<p style="margin: 6px 0px;">Limited advance early bird tickets $150✔<br /> 
Only a few VIP booths available✔</p> 

<p style="margin: 6px 0px;">Go to or contact&nbsp;<em style="background-image:url(&quot;/rsrc.php/v2/yp/r/aeO1ik7i7-T.png&quot;); background-position:0px -4590px; background-repeat:no-repeat; background-size:auto; display:inline-block; height:16px; vertical-align:-3px; width:16px"></em>any committee member for tickets and details.</p> 

<p style="margin: 6px 0px;">Dress Code In Effect: Glamorous&nbsp;<em style="background-image:url(&quot;/rsrc.php/v2/yp/r/aeO1ik7i7-T.png&quot;); background-position:0px -7225px; background-repeat:no-repeat; background-size:auto; display:inline-block; height:16px; vertical-align:-3px; width:16px">✨</em></p> 

<p style="margin: 6px 0px;">&nbsp;</p> 

<p style="margin: 6px 0px;">Link up&nbsp;<a href="https://www.facebook.com/hashtag/nochupidness?source=feed_text&amp;story_id=10154101441998875" style="color: rgb(59, 89, 152); cursor: pointer; text-decoration: none;">‪#&lrm;NoChupidness‬</a></p> 

ich erfolgreich Text angezeigt habe, aber nicht Emoji die auf dieser Zeichenfolge zu bekommen.

+0

HTML-String in der Web-Ansicht anzeigen, habe ich erfolgreich Text anzeigen, aber keine Emoji ist auf dieser Zeichenfolge –

+0

http://StackOverflow.com/Questions/7966922/emoji-and-uiwebview-in-ios-5 –

Antwort

0

Schreiben Sie keine Unicodes für Smileys, es wird nicht angezeigt. Ich hatte das gleiche Problem und was für mich funktionierte, war das Hinzufügen von Emojis aus dem Emoji-Fenster aus der Menüleiste. Wenn Sie versuchen, Emoji in HTML-Datei hinzuzufügen, öffnen Sie einfach Emoji-Fenster, indem Sie auf Bearbeiten> Emoji & Symbol gehen und Emojis von dort hinzufügen. Es wird angezeigt.

Ich hoffe, es wird Ihnen helfen.

+0

aber HTML-Text kommt vom Server (Datenbank), wie kann ich die Emoji in diese Zeichenfolge hinzufügen. –

Verwandte Themen