I am reading data from my database using PHP and I get the result by using echo which I read inside my java code.
The result from my string is as follows:
String mydata;
mydata = "["sdfsd_-sdf","gdf5g7_","fsdfl50","sdfsf_5-X"]"
I had like to split it into array as get this result (without quotes sign):
array[0] = sdfsd_-sdf
array[1] = gdf5g7_
array[2] = fsdfl50
array[3] = sdfsf_5-X
I have used this code to do it:
String[] my_array = mydata.split(",");
However my result is:
array[0] = "["sdfsd_-sdf""
array[1] = ""gdf5g7_""
array[2] = ""fsdfl50""
array[3] = ""sdfsf_5-X"]"
How can i get rid of the ] [
and "?
Thank you