Posts by Vitor Pereira • 117 points
21 posts
-
-1
votes1
answer30
viewsQ: Send and Receive data with popup
I have a list on the parent page as follows: When I click on any row of the table a popup is opened, and I’m doing it as follows: function abrePopUp(ID) { //aqui é o valor do ID que quero enviar var…
-
0
votes1
answer107
viewsQ: Select more than one item with the select tag
I’m having a problem, the html tag allows the user to select only one option from the list, however I need to select more than one select item, how to do this using only JS? I need to select which…
-
0
votes1
answer41
viewsQ: addeventlistener being called irregularly
I have the following code: const setup = async() => { var arrayDados = []; let teuarray = []; var comeco = 4; var index = 2300; teuarray.push({id:1,nome: "arrayDados[i]"},{id:2,nome:…
-
0
votes1
answer127
viewsQ: Get index value created element
const setup = async() => { let teuarray = []; teuarray.push({id:"0",nome: "Vitor"}, {id:"1",nome: "Pedro"}, {id:"2",nome: "João"}); const lista = document.getElementById('lista');…
-
-1
votes2
answers71
viewsQ: Replicate code with JS
How do I replicate the div class Row-tablet with js? I have an array with users and I know the amount, but I don’t know how to replicate all the div and everything inside it. .row-table-head,…
javascriptasked Vitor Pereira 117 -
-2
votes1
answer27
viewsQ: Creating part table link with Divs
.table{ } .row-table-head, .row-table a{ display: grid; grid-template-columns: 50px 180px 70px; width: 300px; margin: auto; } .row-table-head{ display: block; } .row-table a{ text-decoration: none;…
-
0
votes2
answers1590
viewsQ: Promise {status: "pending"}
buscarUsuario.onclick = function() { var usuario = document.getElementById("usuario").value; var resultado = buscaUsuario(usuario); console.log(resultado); } const buscaUsuario = async(usuario)…
-
-1
votes1
answer184
viewsQ: Syntaxerror: Unexpected Identifier 'Promise'
My page is giving the following error: Syntaxerror: Unexpected Identifier 'Promise'. Expected either a closing ']' or a ',' following an array element. This is my Javascript code: var myVar;…
-
0
votes1
answer557
viewsQ: Send checkbox value not selected by form
I have an html form, and in it I have an input checkbox, I need to send the value of that checkbox independent if it is selected or not, if it has selected send 1 if it has not sent 0. So when it is…
-
1
votes2
answers123
viewsQ: Condition "if" does not enter
Why does this type of condition not work in Javascript? if (permissoes[0] || permissoes[5] || permissoes[10] || permissoes[15] || permissoes[20] || permissoes[25] || permissoes[30] || permissoes[35]…
-
-1
votes2
answers837
viewsQ: Add an array inside another already created Javascript
I can create an array within another as follows: var meuArray = [["1","2","3"],["4","5","6"]]; With this I can easily check the positions just by calling meuArray[x][y], where x is which array I…
-
0
votes1
answer90
viewsQ: Change output of an input type time
I have a form with an input of type="time", when I click on Submit the url sends the data like this: hrentrada=HH%3AMM&hrsaida=HH%3AMM. I’d like you to rule like this:…
-
3
votes1
answer1488
viewsQ: Function Returns [Object Promise]
function that takes the data from a url: const getDadosAsync = () => new Promise((resolve, reject) => { let url = 'http://' + host + '/dados'; xhttp.onreadystatechange = () => { if…
javascriptasked Vitor Pereira 117 -
0
votes1
answer54
viewsQ: Function that returns a URL value
How would I transform this function so that instead of sending the date value to prepareListDados() when called, it returns this date value when called in prepareListDados() const getDados = async…
javascriptasked Vitor Pereira 117 -
0
votes1
answer21
viewsQ: Retrieve arguments from a javascript array
I have a page that returns the data as follows: "test,123change,IMPEXPROS,Sarmento:172.20.1.1,172.20.1.2,172.20.1.3,172.20.1.4,172.20.1.5,172.20.1.6,255.255.255.0,192.168.1.1,192.168.1.140:" am…
javascriptasked Vitor Pereira 117 -
0
votes0
answers31
viewsQ: Set image using Firebase database
I need the image that’s stored in the Storage Firebase appear in the listview customized. However, I cannot define the image in the format gs://<Seu banco><childs>. I’ve tried using the…
-
0
votes1
answer43
viewsQ: How to put a scribble on the page
How to put an orange scribble as in the image below in the html page?…
-
0
votes1
answer54
viewsQ: Problems with Node + express routers
I have a sequence of methods (get, post, put, delete), however the put method is wrong and I do not know how to solve. this is the code snippet: router.route('/') .get((req, res) =>…
-
-2
votes1
answer67
viewsA: Why are the Ivs doubling?
discovered the proeblema, the body was smaller than the width of the containers and Divs, Astei add a fixed size larger than them that got everything right!
-
1
votes1
answer67
viewsQ: Why are the Ivs doubling?
I have a one-page code that’s happening something I don’t know about: I have two 100% wide containers, and each has other containers inside. However, after adding a new container with 100% width,…
-
1
votes1
answer68
viewsQ: Why do Divs move after inserting content?
If I take the tags it is aligned right, however when I insert the image or, for example, H1 it already goes down again, if insert in all it goes back to normal, but because this occurs? body {…