android html decoding

前端 未结 5 651
迷失自我
迷失自我 2021-01-06 11:03

I am confused about html text that I need to decode before I display it to the user. I do:

result= Html.fromHtml(temp).toString();

where te

5条回答
  •  情歌与酒
    2021-01-06 11:44

    The \n0006 is Unicode which is not getting translated. Suggestion:

    String temp = "B \u0026 M Collision Repair";
    String result = Html.fromHtml(temp).toString();
    

提交回复
热议问题