Questions tagged as 'jquery'

3
answers

How to change a text variable to number value?

I have this segment of code, I would like someone to help me in transforming the variable P (in which it takes the attribute 'value') and transform it into number value for the sum. $(document).ready(function(e) { $('.pizzad...
asked by 03.12.2016 / 01:41
3
answers

How to insert an element between two elements?

Explanation: I have a <div> parent that contains two <div> daughters, however I would like to insert a <table> using javascript, between, that is, in the middle of these two <div> daughters...
asked by 19.02.2014 / 20:49
3
answers

Increment input values in +1 containing letters and numbers using JQuery?

I have a table with data from check sheets like: bank, account, agency and sheet number, everything was fine so far, but today a customer came with an itau receipt and it has 3 letters followed by a hyphen and the number sequence. example: ABC-...
asked by 20.09.2017 / 18:29
2
answers

How do these sites load your HTML?

I ended up looking at source code from websites like Gmail.com and Secret.ly and I noticed that the HTML is embedded in JavaScript, what technology do they use? It looks like this: <script>var codes = {"AutoControlHeader":true,"CanSub...
asked by 19.11.2014 / 18:53
2
answers

Give alert after entering the word "pass"

How can I perform an alert after the user types "stack". For example, I'm here posting this and after I write stack (without being an input, just writing) it gives an alert. I would have to use keypress and which to check the keys b...
asked by 23.12.2014 / 15:21
4
answers

How to return the last record of an array with Javascript or jQuery?

I'm doing a custom search filter where the user can select the brand and the characteristics of the product and I return the id of them. But I wanted to return only the last record of my arrays where they contain all the information I need....
asked by 17.09.2015 / 14:43
8
answers

How to switch between true and false the checked of an input?

I have this code and would like to switch between true and false the checked attribute of the input. Strangely, you're catching id of label because the web designer overlapped label to input . (function($){ $("...
asked by 05.10.2014 / 02:53
3
answers

How to use this!

I need each button when clicked to turn yellow and the others return to normal ... follow the code and the fiddle: $( "#botoes" ).each(function() { $(this).click(function() { $(".botaoativo").removeClass('botaoativo'); $(th...
asked by 21.09.2014 / 21:56
3
answers

Go to the next element with next and add a class to the previous one

I'm trying to make clicking on the "next" link one of my lists revealed and the previous one being hidden, using a class that has display: none; , tried with .next() of jQuery but there were some problems, such as , for example, in...
asked by 19.02.2014 / 22:28
4
answers

Check for image return via Javascript

How to check if the image returned with 404 error via javascript. Below a sample code, I want to check if the get of this image is 404. If I want to put a certain image, if it does not return the image. <!doctype html> <html lang="...
asked by 03.06.2014 / 19:45