You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi there
I'm new to json-simple, tried to use it to decode a json string that
encoded by PHP(it was 2-dimension array in PHP) json_encode, the string
looks like
{"User_001":{"first_name":"xxx","last_name":"xxx","name":"xxx
xxx","uid":"1571575199","pic_square":"http://profile.ak.fbcdn.net/v230/639/72/q5
71575199_2451.jpg","profile_url":"http://www.facebook.com/profile.php?id=5715751
99"}}
but it reports error at run time:
java.lang.ClassCastException: org.json.simple.JSONObject cannot be cast to
org.json.simple.JSONArray
any idea why? thanks for any help.
Original issue reported on code.google.com by lamka...@gmail.com on 6 Nov 2009 at 10:54
The text was updated successfully, but these errors were encountered:
forgot to include the java code. here it is.
Object user = win.eval("get_user_info()"); // get JSON from javascript
Object user_obj=JSONValue.parse(user.toString());
JSONArray user_array=(JSONArray)user_obj;
Original comment by lamka...@gmail.com on 6 Nov 2009 at 10:57
Original issue reported on code.google.com by
lamka...@gmail.com
on 6 Nov 2009 at 10:54The text was updated successfully, but these errors were encountered: