How to un escape strings extracted from json objects in java? -
in java program download json object, when string it, "what\'s" example, though in php put in "what's". has slashes escape quotes , possibly other characters. there java function can use unescape , turn "what's"?
jsonobject object = new jsonobject(response); firstname = object.getstring("firstname");
if mean remove slashes, use string.replace() method replace \ empty substring.
i think this
string s = yourstring.replace("\\","");
Comments
Post a Comment