![]() |
validacion json - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: validacion json (/showthread.php?tid=81035) |
validacion json - Z4K7 - 01-17-2022 I am trying to send a JSON validation response but it only gives me the same result that I enter a value. PHP Code: $Moneda = model('XXXX')->XXXX($datos); RE: validacion json - iRedds - 01-18-2022 Setting the Output RE: validacion json - remesses_thegreat - 01-18-2022 1. In your code you echoed the result instead of returning. Why is that ? return $this->response->setJSON($data); 2. On the returned error i usually use the following loop. I'm usually working with ApiResponse trait so not sure if it will work for you. Just hope it will be helpful Code: 400: function(response) { |