Android Question json response

tufanv

Expert
Licensed User
Longtime User
Hello

I am using mysql and php method to get data from my server. In my php code, php checks for something and give a json response and my app gets it.

Response from server: "This username already exists"
i want to do something if the response is "This username already exists" but because the response includes " at the start and end of the respnse : "This username already exists" i cant do what i want with If res= "This username already exists" . There must be a simple trick to achieve it but i cant find . Can you help me ?

TY
 

tufanv

Expert
Licensed User
Longtime User
I had to use substring2 to excldue them. If someone has a better idea i would like to listen =)
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…