Answers for "json to array associative php"

PHP
0

php json string to associative array

$assocArray = json_decode($data, true);
Posted by: Guest on January-20-2021
0

json to array php

//2 ways
  //this is for string from $_REQUEST,$_POST to array
$jsonText = $_REQUEST['myJSON'];
$decodedText = html_entity_decode($jsonText);
$myArray = json_decode($decodedText, true);

//this is for json to array
$assosiative_array = json_decode(json_encode($jsonText),true);
Posted by: Guest on July-26-2021

Code answers related to "json to array associative php"

Browse Popular Code Answers by Language