Questions tagged as 'json'

1
answer

Insert an element into an array that contains an object

Hello, I would like to know how to insert an element into an object in an array, in this case, when I add it with the code below, the element is inserted as another index: this.array = []; this.array.push(email); this.array.push({ Mensagem:...
asked by 29.06.2017 / 23:44
1
answer

Problem with window.location

I'm having problems with window.location = "index.php" , it's not redirecting from page login.php to index.php , see code: <script type="text/javascript"> $(function() { $("#loginForm").on("submit", function(a) {...
asked by 30.06.2017 / 23:02
1
answer

How can I convert datetime to date string?

Follow the code: var fullEntries = dbContext.tbl_EntryPoint .Join( dbContext.tbl_Title, combinedEntry => combinedEntry.entry.TID, title => title.TID, (combinedEntry, title) => new {...
asked by 29.03.2017 / 02:05
2
answers

How to insert data with JSON and MVC5

I have a registration screen where the user can enter as many emails as he wants in each record. For this, in my View I have the following code <div class="form-group"> <button type="button" id="btnAddEmail">Adicionar</b...
asked by 21.08.2017 / 22:28
3
answers

jQuery - How to filter a JSON file from an external link?

I have a headache that is as follows: I need to do a filter by names of the following JSON (summarized) ... [ { "index": 0, "age": 25, "eyeColor": "green", "name": "Peck Murphy", "gender": "male", "company"...
asked by 28.02.2017 / 14:01
1
answer

Authenticate a Json API with PHP

I need to do a user authentication in a JSON format API, I have all the documentation for this API. After you authenticate I can make the queries I need. Developer says that I treasure this to authenticate. To access the API it is necessar...
asked by 18.03.2017 / 01:40
2
answers

How to add attribute in JSON array?

I have the following JSON: [{"descricao": "teste", "January": "2454.00", "February": "220.00", "March": "1070.25"}, { "descricao": "teste2", "January": "275.00"}, { "descricao": "teste3", "January": "275.00"}] I need to record in a va...
asked by 24.03.2017 / 12:40
2
answers

convert JSON to object

I have the following json [ {"name":"razao_social","value":"INTELIDER"}, {"name":"nome_fantasia","value":"INTELIDER LTDA"}, {"name":"cpf_cnpj","value":"10.999.558/0001-86"}, {"name":"rg_insc_estadual","value":"132456789"},...
asked by 24.06.2017 / 19:22
2
answers

Json Method - Return

I am developing a return of zip codes through the Post API, the part that is in the controller is working, but I do not know if the return is correct, nor how to use it in the view. If anyone can give me a Light I'm grateful. Controller:...
asked by 18.11.2016 / 03:21
3
answers

I need to check if my JSON is empty to fetch url with parameter defined in the curl

function BuscaMarca(marca, modelo, anomodelo) { marca = $('#marca').val(); tipo = $('#tipo').val(); $.get("curl.php?tabela=BuscaMarca&marca=" + marca + "&tipo=" + tipo, function(data, status) { if (data == 0) {...
asked by 27.10.2016 / 15:30