Questions tagged as 'javascript'

2
answers

How to position a button anywhere on the screen, in html

I'm trying to position a button type button in the center of the screen. For this, I put it in a div , and applied to that div a css that arrows its position in the window. However, the button continues to appear in the left corne...
asked by 11.04.2018 / 22:11
2
answers

Is it possible to save form forms in localStorage with pure Javascript? [duplicate]

I'm a beginner in Javascript and I'm making an application prototype for a college job, and I did not want to use a database or anything, because it's not worth it, I just need to test the GUI. In my application, I have a form, and would lik...
asked by 22.04.2018 / 18:29
4
answers

Select all checkbox when clicking on a checkbox

I tried the solution here in the forum, however it did not work. I want to select all checkbox by clicking only 1 checkbox (select all). Here is my code:                                                            &l...
asked by 17.04.2018 / 20:17
2
answers

How to remove all options from an interactive list and adding new ones using JavaScript?

Hello, I'm working on an interactive menu, in which the user chooses a sandwich and in that act appears a certain list of breads to choose. However, when I select a bread option and then another appears the bread options of the two combos. Follo...
asked by 24.04.2018 / 23:53
2
answers

How to create a menu of tabs like Stack Overflow

I would like to know how I can do to have two links as tabs, for example: <a href="#">Abrir Elemento 01</a> <a href="#">Abrir Elemento 02</a> and clicking on one of these links opens a div with the content co...
asked by 07.10.2017 / 05:04
1
answer

Print JavaScript Object

I have this return in JS, and would like to print the messages like this: Email é Obrigatório! Limite de Testes é obrigatória! ... and so on. The problem is that in the middle of the return in another array and I could not handle it, so in...
asked by 25.04.2018 / 13:34
2
answers

What is the best way to save an image in MongoDB?

I'm developing a JS system with Node server and need to save images in MongoDB in a way that saves as much space as possible, and I'm currently converting the image to Base64 String and saving as an attribute of a document in the collection. B...
asked by 08.10.2017 / 23:50
1
answer

Call function inside another [duplicate]

I have the following code function nomes() { function funcao() { alert("teste"); } function funcao2() { alert("teste2"); } } <input class="todas" id="checkall" type...
asked by 14.10.2017 / 07:40
1
answer

Enter the FadeOut sound when you click the pause button

How can I make the sound come out in fadeOut when I click the pause button? <script> var sounds = [ "sounds/royksopp.mp3", "sounds/9thwonder.mp3", "sounds/thisbeat.mp3", "sounds/mosdef.mp3",...
asked by 09.10.2017 / 21:18
2
answers

How to prevent a property from being removed or modified?

I have an object and would like to prevent certain properties from being modified or removed. The code below is for illustrative purposes: var pessoa = { nome: 'Fulano de Tal', doc: '999.999.999-99' }; console.log(pessoa); pesso...
asked by 31.01.2018 / 06:44