I have this json string:
$row['medium'] = "{\"medium\":13|17|1|14, \"medium_sub\":21}";
now I want to make an array from the "medium" part:
$medium_arr = $row['medium']->{'medium'};
$medium_arr =
explode("|", $medium_arr);
print_r($medium_arr); //This is empty
when I make an array with zero's like (but I know, this makes no sense)
$row['medium'] = "{\"medium\":1301701014, \"medium_sub\":21}";
$medium_arr = explode("0", $medium_arr);
print_r($medium_arr); //This gives 4 results
how is it possible that I can not use the explode in a proper way?
json_decodeand other operations in your actual code, or just in this question?