Tag Archives: json_decode ? Decodes a JSON string

json_decode ? Decodes a JSON string

json_decode function takes json encoded straing and converted to php variable. this function works only for UTF-8 encoded string. for Example check the below code

object(stdClass)#1 (5) { [“v1”]=> int(1) [“v2”]=> int(2) [“v3”]=> int(3) [“v4”]=> int(4) [“v5”]=> int(5) } array(5) { [“v1”]=> int(1) [“v2”]=> int(2) [“v3”]=> int(3) [“v4”]=> int(4) [“v5”]=> int(5) }