Questions tagged as 'javascript'

1
answer

Problem with "on change" followed by "on click"

I have the following HTML code: <input type="text" id="esc" /> <input type="button" value="Ok" id="ok" /> And jquery / javascript: $(document).on("change", "#esc", function(){ alert("esc"); }); $(document).on("click", "#o...
asked by 29.09.2015 / 16:53
2
answers

Show and hide input for javascript search field

Hi, I'm doing the site search bar and the bar template and so: it has an image of a magnifying glass and when you click on the image, under it appears the input to type the search. I'm doing this in JavaScript but I'm having problems. It happens...
asked by 21.10.2015 / 21:03
4
answers

Get ID value and put inside hidden field

Colleagues. I'm getting through the Javascript the value of a result and putting it inside an ID: document.getElementById("ValorUnitarioTriplo").innerHTML = " USD "+triplo.toFixed(2)+""; ............... <div id="ValorUnitarioTriplo">U...
asked by 25.09.2015 / 18:10
3
answers

How to use ng-repeat in a list of an object?

How do I use ng-repeat in the object's Regions attribute? Example: ng-repeat="item in objeto.RegioesFilhas Object: var objeto = { "DescricaoRegiaoVaga": "", "IdCidadeCorreios": "1", "RegioesFilhas"...
asked by 28.12.2015 / 20:00
1
answer

How do I pass this image as a parameter?

The question is as follows, how do I pass the image as a parameter to use it in javascript with tried in the code below? HTML <!doctype html> <html lang="pt-br"> <head> <meta charset="utf-8"></meta> <script...
asked by 09.01.2016 / 07:31
1
answer

Make Variable with multiple names and a single Value String

It would be possible to create a single variable that has the mutual influence of other names on it. In other words, different names for the same statement var , and in the end will have the same value. Example I'm doing this:...
asked by 07.06.2016 / 05:09
2
answers

Paging effect

Note sites and blogs with pagination in the header or footer. When the Anterior or Próximo button is pressed, the bold link is highlighted in the numeric link, signaling the page where the user is currently. Well, in the middl...
asked by 27.05.2016 / 01:39
2
answers

Razor in javascript file

I have a small code that works in _Layout : $.ajax({ type: "POST", url: "@Url.Action("Action", "Controller")", success: function () { //Seu código aqui ... } }); So far everything works fine, but _Layout is gett...
asked by 28.07.2017 / 21:51
3
answers

Value of an input type number [closed]

I'm trying to do an ICMS calculation and am having a seemingly silly problem that is getting the value of the inputs from my HTML, I thought the problem was in the function, but when I try to give alert or console.log() in variable...
asked by 15.08.2017 / 01:53
1
answer

Transform variable into array

I have a variable that calls all people names. var nome = "João Miguel Pedro"; How do I make it to become the following array: var nome1 = ["João","Miguel","Pedro"];     
asked by 14.08.2017 / 20:09