This commit is contained in:
jorgecc
2022-11-07 09:21:06 -03:00
parent 77540a5a00
commit 235c5fc762
8 changed files with 1031 additions and 0 deletions
+20
View File
@@ -0,0 +1,20 @@
<?php
use eftec\ServicesJson\Services_JSON;
include '../vendor/autoload.php';
$s=new Services_JSON();
$array=["hello"=>['a'=>2,'b'=>3],'world'=>[1,2,3,"aaa","bbb"]];
$obj=(object)$array;
echo "Encode array to json<br>";
echo "<pre>";
var_dump($s->encode($array));
echo "</pre>";
echo "Encode object to json<br>";
echo "<pre>";
var_dump($s->encode($obj));
echo "</pre>";