Questions tagged as 'javascript'

1
answer

Javascript - drawRect is interfering with the background color

When I put a square on canvas the background goes white. (function(){ var c = document.createElement("canvas"); var ctx = c.getContext('2d'); var fps = 30; var height = 300; var width = 300; var Bloco = new bloco();...
asked by 16.05.2018 / 00:32
1
answer

Uncaught TypeError: JS Function

Can you help me understand where the error is? function atualizaLista(id_leilao) { if (id_leilao) { $.ajax({ url: 'get.php', dataType: 'json', type: 'POST', data: 'id_leilao=' + id_le...
asked by 02.03.2018 / 03:29
1
answer

How to delete a TAB and its Div and check if it is the last item?

Here is the code for my attempt: $(function() { //for que inicie o tabs e depois de um refresh em todos os tabs existentes. for (var i = 0; i <= 9; i++) { for (var j = 0; j <= 9; j++) { for (var k = 0; k <...
asked by 01.03.2018 / 22:50
1
answer

ref () or child () when reading data firebase web

What is the difference between ref() and child() in firebase? When should I use one or the other? Are there any performance differences?     
asked by 03.03.2018 / 02:06
1
answer

Sort firebase list

Currently I use this function to read the data from the firebase database: function ler() { database.ref(referencia_database).orderByChild('nome').once('value').then(function(snapshot) { snapshot.forEach(function(childSnapshot) {...
asked by 03.03.2018 / 00:00
2
answers

Remove Class from a parent div based on the child element class

I'm using LazySizes to upload images progressively. link This is the style of my project <div class="image-wrap"> <img class="lazyload" src=""> </div> When the images are loading, the IMG tag gains a new...
asked by 02.03.2018 / 22:31
1
answer

Convert JSON to Object with different structure

How can I convert this JSON: {"cliente": [{ "cliente_cpf": "43900404640", "cliente_nome": "Luiza", "cliente_sobrenome": "Azevedo Carvalho", "cliente_genero": "Feminino", "cliente_nascimento": "2000-03-18", "cliente_email": "Luizaazevedocarvalh...
asked by 21.02.2018 / 21:18
1
answer

Calculation between table inputs with creation of dynamic lines

I'm building a table where the rows are dynamically created, on these rows I'm doing a multiplication of the field Qtde * VlrUnitVista and throwing the value in the field VlrTotalVista and is working well, in the first row, i...
asked by 23.02.2018 / 14:15
1
answer

Send email if value meet criteria in column

I have a code that reads a "yes" value in a column and sends an email if that value is there. However, the if I created for this sends even if the value "yes" is not there. The code is below. My if seems to be correct. for (var i...
asked by 14.06.2018 / 06:47
1
answer

Upgrading from IONIC 1 to 3: How to log in to JSON?

I'm migrating from Ionic 1 to 3, and how many changes. I created my login API, with a token: HereIputmyauthorizationcodeforaccessingtheAPI.AndheretheresultinJSON: ion-contentpaddingid="page8" style="background-color:#050505;"> <...
asked by 15.06.2018 / 14:05