Questions tagged as 'json'

1
answer

How to read a JSON that is sent from a webservice on Android?

Hi, I have a php file in a hosting, this file consults and returns the data through a JSONArray. $idusu=$_GET['pkusu']; $pass=$_GET['passw']; if($_GET['opc']=="1") { $sql="consulta..."; $r2=mysql_query($sql) or die(mysql_error()); i...
asked by 09.12.2017 / 02:03
1
answer

Read value of an array json_encode laravel

I did a query to the database ( BD ) which then transforms by means json_encode() to show it in the view blade and the result is this: [{"monto":"44"},{"monto":"0"},{"monto":"5640"},{"monto":"0"},{"monto":"0"},{"mont...
asked by 27.11.2017 / 16:14
1
answer

How to connect to a WEb Service Rest

Good morning. I have to connect to a Web Service Rest to validate CURP with php, I have the url, the username and password of the WS but I have not been able to find the way in which I must connect, I attach the form in which I must send the dat...
asked by 01.12.2017 / 17:04
2
answers

Go through JSON and differentiate between null and empty fields

I'm doing a script in PHP, which allows me to run a JSON to make debug when any of the tags is null, it's a problem is that when you convert the JSON to an array, the data that was empty becomes and remains as null . I attach the code below:...
asked by 30.11.2017 / 14:03
1
answer

Read JSON with Gson in Java

I'm trying to read a JSON file with the following structure, I need to get "one" and "three" { "images": [ { "classifiers": [ { "classifier_id": "id",...
asked by 21.02.2018 / 19:41
1
answer

How to pass data with json

I need to pass from PHP a JSON to each field that corresponds the value, for the moment I try with the value of select and you are supposed to put it in the cedula field. I attach the code $(document).ready(function(...
asked by 14.01.2018 / 23:03
1
answer

Receive Json WebService

I have to get an answer from an external web service that contains a json, this answer has to reach my web service, let's say https://ejemplo/json and since I'm new using web service I do not know how to do this, my idea is that I come th...
asked by 28.10.2017 / 18:44
1
answer

Load select element with ajax

I would like to make a query and collect it both in a text box and in a select. I can capture the query in a text box, but not in the select. Index.php <script> function cargar_energia(){ //var n = document.getElementById("nombre")...
asked by 26.10.2017 / 14:40
1
answer

Insert image in json

Very good, I'm going through a json in php and it depends on the value of one of the fields, I would like to concatenate an image to the field, if I put a text works well but doing it in this way with an image does not. Any suggestions? Thanks...
asked by 20.10.2017 / 17:26
1
answer

How to test sending a JSON using Web Service by POST in php?

It turns out that I have the following method where I receive a JSON and get the values of its items by sending to save to the fields of a database Method that receives JSON <?php require 'meta.php'; if ($_SERVER['REQUEST_METHOD'...
asked by 11.10.2017 / 04:41