D
D
Denis2017-05-02 20:52:41
Android
Denis, 2017-05-02 20:52:41

How to convert HTTP string to UTF-8?

How to convert a string

<p dir="ltr">&#1055;&#1088;&#1086;&#1074;&#1077;&#1088;&#1082;&#1072; &#1088;&#1072;&#1073;&#1086;&#1090;&#1099; &#1088;&#1077;&#1076;&#1072;&#1082;&#1090;&#1086;&#1088;&#1072;</p>

obtained using the android.text.Html.toHTML method from the EditText.
In the way it should look like "Checking the work of the editor"
URLDecoder does not work, as it is intended for characters like "%97"
Or is it possible to get text from an EditText with html tags, but in utf-8 encoding, so that it would not have to be converted?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrew, 2017-05-03
@lacredin

Try stackoverflow.com/questions/22093908/android-spann...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question