Questions tagged as 'json'

4
answers

How to alphabetize a select obtained through a JSON?

I set up a select through JSON below, the only problem is that it follows the order of the key, how to organize it alphabetically? { "12": "Acre", "27": "Alagoas", "16": "Amapá", "13": "Amazonas", "29": "Bahia...
asked by 11.07.2016 / 19:54
1
answer

Cross-origin request blocked

I'm using an Elsevier API to fetch a book listing. To do this, I'm using an example from them at this link: link I did my registration, got my APIkey and got the following code: <html> <head> <title>Elsevier ScienceDirect S...
asked by 21.11.2014 / 11:58
2
answers

How do these sites load your HTML?

I ended up looking at source code from websites like Gmail.com and Secret.ly and I noticed that the HTML is embedded in JavaScript, what technology do they use? It looks like this: <script>var codes = {"AutoControlHeader":true,"CanSub...
asked by 19.11.2014 / 18:53
2
answers

Get JSON from the URL properly

I have the following method that gives me a String : public static final String jsonClientes = " {\"clientes\": " + " [" + " { \"idClientesT\": 1," + " \"tipo\":\"s\"," + "...
asked by 14.12.2018 / 14:20
2
answers

Error "An error occurred while processing your request. "

I've developed an application in MVC C # for reporting in JSON, in my%% of cases it works normally, the query takes a long time because I get 2 to 3 databases depending on the report, the application in Azure, most of the time it gives an error...
asked by 10.10.2014 / 16:58
2
answers

Send Model Razor with $ Ajax Serialized to Controller

I'm trying to send an object to controller , using ajax . The object goes to the controller with Json , but only recognizes the values of the get, not the post. $.ajax({ type: "POST", url: "@Url.Action("Adi...
asked by 13.06.2014 / 19:01
3
answers

How to make the page load only after getJSON returns?

I'm retrieving a list in JSON using the jQuery.getJSON function: http=jQuery.getJSON(url); This code returns the object perfectly, but the request takes longer than the loading time of the page where I will insert the data. This way,...
asked by 11.09.2014 / 18:02
3
answers

Convert object to json in php

I'm trying to create a class that saves objects of type Conta to a json file, however, when saving the file, the object information is not saved, just this:    [[], {}] My class that is reading and saving in json is: class JSONCu...
asked by 10.11.2015 / 18:13
2
answers

How to check if a response (date) is a json

How can I check if a result (date) coming from an ajax request is json or not? I tried this code but I did not succeed var obj = $.parseJSON(response); if(obj.avatar) { } else { }     
asked by 10.12.2014 / 18:35
5
answers

Change return / Date (1386295200000) / to date format

I have a return of json that comes from SqlServer : /Date(1386295200000)/ How to convert to date format dd/mm/yyyy ?     
asked by 22.03.2018 / 20:12