I have the following case: I receive a variable _POST that brings two data in JSON format and I need only take one of those data. I try this, but the result is NULL. Any suggestions? Thank you very much
<?php
$CuentasBancariasSel=$_POST["CuentasBancariasSel"]; //Recibo: array(1) { [557]=> string(33) "{'id_cuenta':'1','id_banco':'39'}" }
$obj = json_decode($CuentasBancariasSel);
$CuentasBancariasSelOK = $obj->{'id_cuenta'};
?>