Questions tagged as 'javascript'

3
answers

Change String Y-axis and Google Chart

I use Google Chart to generate graphics. I have array with values from 1 to 4. These values are of type int . I need to change the description of the Y axis. To: 1 = Great, 2 = Good, 3 = Regular, 4 = Bad. Iwouldlikeitt...
asked by 07.11.2016 / 19:34
2
answers

Open View with Parameters [duplicate]

I have this script: $('#Musico').change(function () { var id = $(Musico).val(); var url = '@Url.Action("Votar","Chamada")'; var tipo = 1; $(function ChamaVotar() { $.post(url, { id: id, tipo: tipo }); });//Functi...
asked by 25.11.2016 / 00:31
2
answers

Hiding half of a content

How do I do what is illustrated in the image? Knowing that content is not just text but buttons and other things on the home page of a site!     
asked by 27.12.2016 / 14:55
2
answers

Function Optimization (probably with for loop)

I'm having difficulty developing when we talk about for ... The basics I can understand now in practice ... People have developed this code and I believe it can be reduced to a few lines with. Notice that in the input range change it appears...
asked by 24.01.2017 / 22:47
3
answers

Convert string with HTML tags to an array

Consider the following string: var texto = 'Esse é um texto de <span class="red"> teste </span>'; I need to transform the string into an array separating by space, that is: var palavras = texto.split(" "); The problem is th...
asked by 28.08.2018 / 01:15
2
answers

how to automatically fill in an input?

As the code with several textfields shows, I want to make visible just dataEntrada, dataSaida and KM and from these 3 fill in the others that will be invisible, the amount to be paid will be displayed in an alert when you click on simulate. Th...
asked by 03.06.2018 / 01:27
1
answer

How to identify if an element was removed from the page in real time

How to identify with JavaScript, if the user removed a div from the page through the element inspector, ie if the id of the element no longer exists on the page, perform an action. Simple example: If% is removed, <...
asked by 18.08.2018 / 16:45
3
answers

Assign values to arrays

I noticed that by incrementing a value to a array using the following syntax: let array = []; array['nomeIndice'] = 10; length of this array is not incremented, and remains in 0 , even though array contains...
asked by 12.08.2018 / 18:15
3
answers

How to pass the value of a variable to an input hidden?

How can I pass value of a Javascript variable to a input hidden ?     
asked by 19.12.2016 / 23:27
2
answers

When to start the site already request the login

I'm creating a website and I have a question. How do I do when the user enters the URL address or click a button that goes to admin.html, and automatically appears the login page? or as soon as you start admin.html already appear first the login...
asked by 26.12.2016 / 01:00