viernes, 18 de agosto de 2017

returning as json content type

<?PHP
$data = /** whatever you're serializing **/;
header('Content-Type: application/json');
echo json_encode($data);

https://stackoverflow.com/questions/4064444/returning-json-from-a-php-script

No hay comentarios:

Publicar un comentario