Questions tagged as 'json'

3
answers

Browse JSON in PHP

I have a problem that I can not solve, I am still a novice in this. I receive in a php file the following JSON that I decode in this way. $resultado=json_decode($_POST["datos"]); and when I show the result variable it throws me down. {"n...
asked by 04.07.2018 / 09:17
5
answers

ListObject to String in Java

I have a List of an Object. public class BusStop { private String description; private float lat; private float lng; //getter and setter } Of which I try to put all its content inside a variable of type String. I tri...
asked by 10.05.2018 / 12:06
2
answers

Change the id of a Youtube video in HTML

I'm trying to change the id of a video in my html, which is in another javascript file, where the youtube API is created. I also read the ids of a JSON file. HTML <div class="video-container"> <div id="player"> <scri...
asked by 07.05.2016 / 14:37
1
answer

How can I print the student with the highest grade and the student with the lowest grade of this JSON?

I need help in this exercise and I need to print the name of the student with the highest grade, and the student with the lowest grade of the next JSON: /* est == estudiantes, 5.0 == Nota Maxima, 0.0 == Nota Minima */ var est = [...
asked by 22.02.2018 / 04:14
1
answer

Is it possible to change the name of a property in a Json or Json array?

I need to change the name to a Json property from an array [ { nombre : 'Luis', apellido : 'Gonzales' }, { nombre : 'Maria', apellido : 'Perez' }, { nombre : 'Ignacia', apellido : 'Valdebenito' } ] and I need to modify it in the follo...
asked by 04.03.2016 / 02:53
6
answers

Problem when returning a list of JSON objects with AJAX, I can not access the properties of the object

Good morning, I have this web service: [ScriptMethod(ResponseFormat = ResponseFormat.Json)] public string ObtenirProvinciaByPoblacio(int CodiProvincia) { clsCRUD _ou2 = new clsCRUD(); try { _ou2....
asked by 28.01.2016 / 17:08
1
answer

Problem when creating JSONObject in android studio

I am creating a login in Android Studio guiding me from a tutorial but I have been stuck, when creating a JSONObject there is something that fails and I do not know what it is. I have managed to create a String with the valu...
asked by 18.02.2018 / 00:36
2
answers

How to get a json's length

I have a problem trying to traverse a json to get its length (length). This is my code: var parametros = { yMin: "0", yMax: "300", ySteps: "5", yLabel: "users", xMin: "1", xMax: "12",...
asked by 16.12.2016 / 06:18
1
answer

Validate a JSON and print it formatted

Suppose I copy a string in a textarea, for example: var str = "{ hello: 'world', places: ['Africa', 'America', 'Asia', 'Australia'] }"; So with JSON.parse(str) I parsed the string in JSON format, but I would like to show the result i...
asked by 24.01.2018 / 12:58
1
answer

Why does JSON.stringify () return an empty array?

/* Validar checkboxes clickeados */ var checkboxes = document.querySelectorAll('.single-checkbox'); var clickeados = new Array(); checkboxes.forEach(elem => { elem.addEventListener('change', (event) => { event.stopPropagation()...
asked by 26.11.2018 / 17:53