Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] How to escape Unicode with JSON.toString()?

Hi Joakim,

no, I am already sending "application/json; charset=utf-8" - so that
is not a problem.

And also ADM error talking about XML unfortunately means nothing, they
mention XML in all their error messages I have seen sofar while
developing (while their API expects JSON being POSTed).

I understand, that encoding UTF-8 chars to \u#### is optional.

But is that possible with jetty-util-ajax or should I switch to some
other lib for JSON encoding?

When I look at
https://github.com/eclipse/jetty.project/blob/jetty-9.4.x/jetty-util-ajax/src/main/java/org/eclipse/jetty/util/ajax/JSON.java
then it can decode \u####, but jetty-util-ajax do the reverse thing too?

I have also posted my question at
https://stackoverflow.com/questions/49538806/how-to-escape-unicode-with-json-tostring-method-in-jetty-util-ajax

Thank you
Alex


Back to the top