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

これはHTML文字列iOS 9で絵文字をウェブビューで表示するにはどうすればいいですか?

<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> 

である私は正常にテキストを表示するが、この文字列に絵文字のを取得していません。

+0

ウェブビューでhtml文字列を表示すると、文字列を表示できますが、この文字列には絵文字は表示されません。 –

+0

http://stackoverflow.com/questions/7966922/emoji-and-uiwebview-in-ios-5 –

答えて

0

スマイリーのユニコードを書き込まないでください。表示されません。私は同じ問題に直面し、私のために働いたのは、メニューバーから絵文字ウィンドウの絵文字を追加することでした。 emoji &のシンボルを編集してそこから絵文字を追加すると、絵文字をhtmlファイルに追加しようとしているときに絵文字ウィンドウを開くだけです。表示されます。

ご希望の場合はお手数ですが、

+0

htmlテキストサーバ(データベース)から来ていますが、その文字列に絵文字をどのように追加できますか? –

関連する問題