Questions tagged as 'javascript'

2
answers

How to create a formData.append to be able to send inputs of type File?

I want to send a input type="file" from a form , to send all the data of my form I use the formData , which I created from scratch in order to capture each of the data that exists in my form and receive it on a page php , on this page I can...
asked by 24.06.2016 / 01:35
4
answers

Get input name values with Jquery

I have an application with several checkboxes, and this code with Jquery : var checkboxes = $(".borrar_contacto"); console.log(checkboxes); And this with JavaScript : var checkboxes2 = document.getElementsByClassName("borrar_contacto");...
asked by 23.01.2017 / 06:04
3
answers

"Next and Previous" buttons

Good afternoon, I'm a little new to the subject and I have a test application which has two buttons to go to the next question and to go back if you want. The fact is that I have no way to square them well because if the question is very long, t...
asked by 23.01.2017 / 17:24
2
answers

How to put ellipses in a text with JQUERY

I have a table which brings me from the database a description which varies the number of characters, the problem is that if a description has "1000" characters are shown in the table and that looks bad then I look for the way of being able to s...
asked by 25.01.2017 / 15:18
4
answers

Difference between $ ("# item") and $ ("# item") [0] Jquery

I'm trying to understand how Javascript and Jquery work. I know this: var contenido = document.getElementById("contenido"); contenido.text("Hola desde Javascript"); It's the same as this: var contenido = $("#contenido"); contenido.tex...
asked by 22.01.2017 / 21:57
2
answers

Drag and drop, have all the elements on one side or the other

I have the following code, it is a simple drag and drop. It happens that when I move the elements of div1 to div2 I can move all the elements, but when I try to move the elements of div2 to div1 I can only move one at a time. The question is how...
asked by 30.07.2018 / 15:36
2
answers

Using localStorage to hide a div

Basically the problem I have is that I do not know how to hide the input and the button with localstorage , so when I refresh the page I do not show the input or the button, just the name. HTML <span id="label-user"&g...
asked by 29.03.2017 / 11:52
1
answer

Error adding N elements with Javascript

I have a problem adding all the totals, it manages to add the totals of each product and a final total but when editing a price or quantity it is added to the final total and it is not edited correctly. Code: <!DOCTYPE html> &l...
asked by 28.03.2017 / 17:50
2
answers

Delete JavaScript DIV elements

I'm trying to remove all the elements of the class cupcake from my dom to repaint them based on a filter. I'm doing; let cupcakes= document.getElementsByClassName("cupcake"); alert(cupcakes.length); for(element of cupcakes){ c...
asked by 05.12.2018 / 20:01
2
answers

filter json object by date range

accounts =[ {id: "1", name: "item 3", amount: "15" date:"10-10-2018"} {id: "2", name: "item 2", amount: "200" date:"9-11-2018"} {id: "3", name: "item 3", amount: "300" date:"16-12-2018"} ]; I have an array that stores json objects and...
asked by 16.12.2018 / 16:30