java - Convert a string that is formatted as JSONObject into a proper JSONObject -


i have string formatted giant jsonobject.

string bodyoutput = "{"type":"type1","content":"content1"},{"type":"type2","content":"content2"},{"type":"type3","content":"content3"}"; 

how can format string , turn proper jsonobject?

if try following below, grab first value of "string"

jsonobject bodyobj = new jsonobject(bodyoutput) bodyobj = "{"type":"type1","content":"content1"}"; 

thanks


Comments

Popular posts from this blog

sql server - Cannot query correctly (MSSQL - PHP - JSON) -

php - trouble displaying mysqli database results in correct order -

C++ Linked List -