Most voted "jquery" questions
jQuery is a Javascript library focused primarily on DOM handling, event management and Ajax, seeking to free developers from directly dealing with a number of browser compatibility issues.
Learn more…11,371 questions
Sort by count of
-
1
votes1
answer1943
viewsOpening HTML inside a DIV does not recover the parameters via GET
I am using Jquery to load an HTML page into a <div>. My code is working correctly, but it’s not passing a value via GET that I need on the other page: <!DOCTYPE html> <html>…
-
1
votes1
answer18787
viewsStart with hidden div and show with button
Based on the answer below, I created the button that displays and hides the div, but what I would like is that the div started already hidden and had a button to display it. How could do? How to…
-
1
votes2
answers81
viewsIdentify DIV by complex id
I have several Divs dynamically loaded via PHP like this: <div class="projeto" id="-9-3-21"></div> <div class="projeto" id="-3-1-77"></div> <div class="projeto"…
-
1
votes0
answers29
viewsFunction Check initial and final product
Good afternoon, I’m developing an export screen to generate a product report per cycle and low area. However I need to filter between initial product and final product, in case I have a Function to…
-
1
votes1
answer901
viewsStop settimeOut Javascript
Well I am doing a function to check certain iteration and if it passes x I pause the contactor, however it is not working, it continues to appear Alert window, follow my example below? function…
-
1
votes1
answer75
viewsHow to access # property in a JSON file with Jquery?
Hello, I am using the Last.fm api and I am having difficulty accessing the #text found inside the image array. Data link -> JSON I try to: console.log(values.track[index].image[index].#text); But…
-
1
votes0
answers36
viewsHow to send an object from one page to another without nodejs
My question is the following know that there is the nodejs to make the connection from Servers to customers. How can I get from one page to send a json type object to another. It would be something…
-
1
votes1
answer1559
viewsHow to do a back post (refresh) on MVC
I am new to MVC and am used to web Forms and the events of the controls that cause postback and update the page. I need to do this update on the MVC page after a javascript is triggered. In the code…
-
1
votes1
answer89
viewsMacros in coordinates related to the textarea
I need to insert some macros in a text area, these macros can be inserted anywhere in the field, currently I only use one append that just puts the macro at the beginning. I’m thinking of getting…
-
1
votes2
answers2038
viewsHow to transform text into input text when clicking?
So, I need to transform a text that is inside an HTML tag into input text to edit it. What better way to do this ? Example: http://www.codigopronto.com/codigos/Texto-editavel-com-JavaScript.php…
-
1
votes2
answers560
viewsValues from one form to another
In the index.html will have a pre-form with name, email, city and UF. I will need to take this data and play for another form that will be in another html file. I have a certain notion in jQuery,…
-
1
votes1
answer159
viewsPick up value from a Hidden field outside the php loop
Colleagues I have a php code that brings the value of the product from the bank. <?php ... while($jmMostrar = mysqli_fetch_object($sqlMostrar)){ $mostrar = "<input type='hidden' id='produtos'…
jqueryasked 7 years, 8 months ago user24136 -
1
votes2
answers263
viewsTaking ID of the upper click div
I need to get the ID of the DIV superior to what the button is, for example: <div id="1"> <button id="1"></button> </div> <div id="2"> <button…
-
1
votes1
answer120
viewsLoad Page with Swipebox
I want you to open the page and open a Swipebox with an image. http://brutaldesign.github.io/swipebox/#Try I did so: jQuery if($('.swipebox')[0]){ $('.swipebox')[0].click(); } // Swipe Box…
-
1
votes2
answers81
viewsHow do I pass this function to a php file called Geolocation via ajax?
var x = document.getElementById("demo"); function getLocation() { if (navigator.geolocation) { navigator.geolocation.getCurrentPosition(showPosition); } else { x.innerHTML = "Geolocation is not…
-
1
votes1
answer226
viewsJquery does not validate Incorrect password
I got the following jQuery $(document).ready(function(){ $('#email').focus(); $("#formLogin").validate({ rules :{ email: { required: true, email: true}, senha: { required: true} }, messages:{ email:…
-
1
votes1
answer129
viewsHow to prevent jQuery’s close function from destroying my message container?
When I click the close icon of the error message, the Bootstrap javascript function simply destroys the container #msg receiving error messages preventing the next time an error occurs the container…
-
1
votes1
answer79
viewsLeave the bar centered using dragdealer.js
I am using this library to create bars that the user can interact with: http://skidding.github.io/dragdealer. I would like the drag bar to start at 0, that is, in the middle of the bar: But I have…
-
1
votes2
answers261
viewsSet the value of the input whose name has brackets
As described in the title, follow the example below: ---- HTML <form id="nameGenderForm"> <table id="teste"> <tr> <th >Name</th> <th >Gender</th>…
-
1
votes1
answer274
viewsHide element after it is loaded on page
I have on my page the following google script: <body> <!-- Google Tag Manager --> <noscript> <iframe src="//www.googletagmanager.com/ns.html?id=GTM-abcdef" height="0" width="0"…
-
1
votes0
answers281
viewsfloating banner covering the entire page
I want a banner or a div that is in the middle of my page is that in this banner has a button to close it is that until it closes it is not possible to have access to anything of the page..…
-
1
votes2
answers17712
viewsInputmask() function for Cpf and cnpj
I’m using the plugin Inputmask, the following JS code $("input[id*='cpfcnpj']").inputmask({ mask: ['999.999.999-99', '99.999.999/9999-99'], keepStatic: true }); Man input is taking the mask of Cpf,…
jqueryasked 7 years, 7 months ago matheus.paulo93 37 -
1
votes2
answers513
viewsAutocomplete with jquery and mysql does not list the options when starting to type
I have the following form: <?php //CHAMA A CONEXÃO COM O BANCO DE DADOS require('../db/conexao.php'); ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8">…
-
1
votes0
answers171
viewsjQuery datatable sAjaxSource - Show error while searching
At great cost, I was able to find an ajax code for loading the tables. It was necessary, because there are more than 5 thousand records. Error appearing while searching: Datatables Warning (table id…
-
1
votes0
answers155
viewsJquery and keyboard on android and IOS
i am having difficulty capturing which character the user pressed when using smartphone with ANDROID/IPHONE. I use the jquery keyup event, but the answer is always Undefined or 229. Someone knows…
-
1
votes2
answers1366
viewsHow to check if a DIV has an ID
Is there any way to check if a div has an id, using jQuery? I can check if he has an ID value, so: <div id="main">...</div> if ($("#main").length){ // resto do código aqui } But what I…
-
1
votes0
answers22
viewsRemember the status of the item with cookies
https://jsfiddle.net/kmvo2wum/ I wanted, in case the user opened one of the main items, giving refresh, to remain open. I’ve tried it a few ways but I haven’t been able to, if anyone can help, I’d…
-
1
votes1
answer168
viewsClose Form Dynamically jQuery
The form is a registration form for a cat hotel. The form has the option to add more than one cat per registration, so I clone the cat’s registration form to include the second cat, but I can’t get…
-
1
votes1
answer157
viewsHow can I add paragraphs to a TEXTAREA TAG?
$("#text").on("focus", function(){ $(this).keypress(function(e){ if(e.keyCode == 13 | e.which == 13){ //this.value += '</p><p>'; document.execCommand('formatBlock', false, 'p'); } });…
-
1
votes0
answers266
viewsLoad header and footer with . load() and make it visible to Google
I’m setting up a pure HTML site, which has the following structure Whereas I don’t have a Master Page like in ASP.NET, I need to replicate the header and footer to other pages using the function…
-
1
votes1
answer570
viewsBlock events with jquery
I have been for some time searching the jquery documentation for a function with the following behavior Suppose we have two buttons on the screen each with a different click event:…
-
1
votes1
answer278
viewsCheck if an email was typed in text field with jQuery
Good afternoon! How do I check if an email has been typed within a text field? I need to identify when the user clicks outside the field, whether an email was typed or just a name, for example.…
-
1
votes2
answers66
viewsRight way to get a certain div
I’m trying to figure out a way to access a div via jquery to manipulate it. Follow the code: <div> <!-- Essa é a div que quero acessar --> <div> <div> <div…
jqueryasked 9 years ago Diego Souza 1,030 -
1
votes1
answer53
viewsHow to capture the value of the current attribute with jQuery?
I have the following form in html: <form>First name: <br> <input type="text" name="nome"> <br>Last name: <br> <input type="text" name="sobrenome"> </form>…
-
1
votes1
answer851
viewsReload table without refresh with Ajax jQuery
I have a table that has the option to update records, but need that when changing a record it is changed dynamically in the table without the need for refresh.. already working the part of the…
-
1
votes2
answers2719
viewsAdd and remove Jquery class
I have a toggle effect that opens and closes a div, and in this effect, I put to add a class and remove. It adds the class, but is not removing it. Why? Jquery…
-
1
votes2
answers87
viewsHelp with concatenating
I need to pass a variable inside an item array, a parameter that only accepts string, but when I pass a variable the API does not accept, it says that the parameter is incorrect. Better explaining:…
-
1
votes3
answers3386
viewsLimit of input characters
I want to assemble a jQuery that applies a limit of 255 characters within the input. My idea and do something like that: $(".loading").on('input', function () { // aqui eu tenho que fazer o bloqueio…
-
1
votes1
answer973
viewscompare two dates in jQuery
Good morning $("#salvar").on('click', function(e){ var startDate = new Date($('#data_abertura').val()); var endDate = new Date($('#data_encerramento').val()); alert(startDate); if (startDate >…
-
1
votes1
answer349
viewsMake code only work on Desktop
How do I make a code, Jquery/Javascript work only on Desktop? That is, on mobile phones and tablets, I do not want it working... With CSS I use Media Query, but with Javascript I get lost. Thank…
-
1
votes0
answers126
viewsTinymce - Responsive file manager: Undefined error "defaultView" in jQ version 1.6
When I try to insert a file it does not open the file management window and gives the error: Uncaught Typeerror: Cannot read Property 'defaultView' of Undefined I tried running with jquery 2.1.4 but…
-
1
votes1
answer199
viewsHow to Get Selected Jstree Root
Galley, good afternoon, a doubt, I’m using the Jstree and I need some help. When I select the child nodes : I can get them through the script : $('#arvore').jstree(true).get_selected(). But I can’t…
-
1
votes1
answer5296
viewsCopy text by clicking on a DIV
How do I, with Jquery preference, when clicking the ola class div: $('ola').click(function(){ //FUNÇÃO DE COPIAR AQUI }); Does it copy a text? For example, by clicking on the ola class div, it copy…
-
1
votes1
answer178
viewsHow to convert date at select time and return via Json
In my form I am using the Bootstrap-Datepicker so that the user can inform the desired date at the time of registration, works correctly, but at the time of making a change I am trying to bring the…
-
1
votes2
answers65
viewsKeyup event should not activate with special keys
In my document I am creating some keyboard shortcuts to facilitate the use of the page itself, and I am doing it as follows: $(document).on("keyup", function(e){ /*Tecla C*/ if(e.which === 67){…
-
1
votes1
answer841
viewsUpdate content of DIV
Is it possible to update the content of a DIV? I have a DIV in which I pick up data present in the browser cookies and make a foreach to the listing of the items of cookies showing them to the user.…
-
1
votes3
answers5502
viewsRemove TAG with Javascript
How to remove an HTML tag using Javascript? For example, with insertAfter(); and insertBefore(); I can insert some tags if I want. But if I want to delete from my code, some TAG? Not by display:…
-
1
votes1
answer493
viewsHow to put the return of Ajax [form] inside a div?
$.ajax({ url: 'executa.php', type: 'POST', data: {emailDestino: emailDestino}, dataType: 'html', success: function(data) { $('#notifyInscrito').appendTo(data); } }); I’m going to the file room…
-
1
votes1
answer22
viewsbug Multiply Coins flip jquery
I’m developing a kind of old game, but there is an error that is getting in my way, I need the flip animation to work all the coins however, it only works at first ignoring the others.…
-
1
votes1
answer34
viewsGoogle Charts with code on body to request
Guys someone has already used goolecharts ? I can only make the plot if it is in the head, how do I make his code stay in the body ? 'Cause I want to plot via a request