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
answer7571
viewsEach in JSON jquery date
I’m trying to walk a array de objetos with jquery I’m doing so: $.getJSON('http://localhost:8000/produtos', function(data) { $(data).each(function (item) { console.log(item);…
jqueryasked 8 years, 1 month ago Renan Rodrigues 3,709 -
1
votes2
answers151
viewsRemove div if input is empty
I’d like to rule that out div if the input receive an empty value. <div class="form-group col-md-2 usuario"> <label>Usuário:</label> <input type="text" readonly…
-
1
votes2
answers64
viewsI can’t get the value of the column next to my input
I have a problem I don’t know why... I have a table in which one of the columns gets the input and when onkeyup in this input, I need to get the innerHTML from the column next: <script…
-
1
votes1
answer74
viewsTake the ID value and play in a variable
Well my problem is that I am working with table Father x Son and when I create a new line, all inputs receive different Ids and needed to pass what is inside the ID to a variable Example: <input…
-
1
votes0
answers138
viewsUsing jQuery + Requirejs + Angularjs correctly
I’m trying to get the file themes/cms/build/js/main.min.jsfunction properly after being charged by Requirejs, but I haven’t been succeeding. The file is loaded, some functions works like…
-
1
votes1
answer66
viewsDuplicity in Datatables.net jquery
I have Modal window that adds Customer Address, the problem is that the added addresses get duplicated, I am using the Datatables.net pata list the addresses. The process to add the addresses is…
-
1
votes2
answers91
viewsJS not formatting the thousand value correctly for Input and not receiving correctly in PHP / Database
Good morning people, I have in my forms some input’s where the user informs the value of the product, its quantity and with this is made the calculation of the Product Value and also the Total Order…
-
1
votes1
answer72
viewsValidate value of a select
<label>Itinerário</label> <select id="itinerario" name="itinerario" class="form-control form-control-sm" required readonly> <option value="" selected>Selecione um…
-
1
votes3
answers74
viewsHow to activate only the next div?
On my page I have several elements that I prefer to hide so as not to make the site too big, but when clicking to show one, it expands all of the page. How do I make him select only the next…
-
1
votes1
answer20
viewsHow to remove parts of a field name in a serialized structure?
I am selecting my form to then convert it to JSON, and I need to remove the string "PessoaViewModel." of all Fields. The serialized data looks like this:…
-
1
votes2
answers1324
viewsParallax effect is not working on mobile
I’m developing a new website here from the company http://teste.softlove.us/ And everything is working (effects and sizes), I’m using Bootstrap and jQuery, except in mobile that in Home and About Us…
-
1
votes1
answer222
viewsHow to perform an action when finishing each() Jquery
I’m using the function each() of Jquery would like to know if there is a mechanism so that I can perform a function after the each(). As soon as I finish mine each(), I can do something else, but it…
-
1
votes0
answers38
viewsProblem to the div ordenard
I have 1 problem, I am using JS to sort DIV’S (works correctly), the problem occurs when I click on the button "edit that same div", with the image becomes easier to preceber. If I do not change the…
-
1
votes1
answer136
viewsDoubt about using checked="checked" in a jquery function
I have a form and wanted that when the page was loaded, if my checkbox is set, disable the "disable" form property. In the code example below, I put checked="checked" but only works if I click to…
-
1
votes2
answers28
viewsPlay an audio starting in 10 seconds
I’m controlling some audios on a website and I’m needing some specific audios to start on second 10, so far it’s like this: var minhaMusica = new Audio(); minhaMusica.src = 'musica.mp3";…
-
1
votes1
answer111
viewsCan you get Event.preventDefault() if the call has parameters?
I’m doing an operation where I got the call of a method, in this specific case how I could catch the event.preventDefault() form. <button type="button" class="btn btn-primary"…
-
1
votes2
answers203
viewsjQuery - Select option and return values
I have the following form: <div class="form-group"> <label for="sms_mensagem" class="col-sm-2 control-label">Mensagem Pré Definida</label> <div class="col-sm-10"> <select…
jqueryasked 8 years, 1 month ago Sr. André Baill 6,946 -
1
votes3
answers2458
viewsHow to delete Input Placeholder when Clicking inside the Field
I’d like to know how to erase the placeholder of a input when clicking inside it. When searching here I saw answers on how to delete the value but I found nothing about placeholder. I would like a…
-
1
votes0
answers71
viewsSending of Modal Multiselect data
I would like a help with this code: I am sending information from a table for modal and this table will have data of the groups separated by comma and I would like it to be selected in the modal in…
-
1
votes0
answers22
viewsHow to divide a page into tabs
I’m making a site that I’ve hosted but after that , I saw that it’s very slow because it has many images to load at once, so I thought I could divide it into tabs to get to 10 elements and buttons…
-
1
votes1
answer34
viewsFill inputs by pasting only one
I have 4 empty inputs and I have 4 paragraphs of text typed in the word. Would there be a way to copy the paragraphs and when paste into the first input it identify line breaks and distribute by…
jqueryasked 4 years, 4 months ago Matheus Soares 85 -
1
votes1
answer54
viewsbreak automatic line with database data
Hi, I have a ul with li's who are named after products. It turns out that when I change the resolution to mobile, for example 320px, so if the name of the product is big, then it won’t fit inside…
-
1
votes1
answer349
viewsHide button (p:commandbutton), Primefaces, with PF api
I’m trying to accomplish something seemingly simple, but I’m taking a hell of a beating... Studying, I read that Primefaces has a javascript / jquery api, so I decided to take a look. Turns out I…
-
1
votes1
answer204
viewscapture value from another input with jQuery
Guys I set up a system that when typing the user name in an input, jQuery captures the name and calls a php file. Which in turn makes a BD query and fills a select list. Well the structure is like…
-
1
votes1
answer41
viewsjQuery Menu function select url browser
How do I make the code window.location.href with the right value of <option: <script type="text/javascript"> jQuery(document).ready(function($){…
jqueryasked 8 years, 1 month ago valdir silva 89 -
1
votes3
answers184
viewsReturn BD values via ajax
I have a screen where I must popular with database values using ajax. When I click on the button to fill the fields the following error appears: Failed to load Resource: the server responded with a…
-
1
votes3
answers1306
viewsEmpty string passed to getElementById()
I’m using the jQuery and I have the following code jQuery(document).ready(function($){ $(".checkParcelamento").click(function(){ var bandeira = $("#bandeiraCartao").val(); var numero_cartao =…
-
1
votes1
answer39
viewsHow do I copy/select a var in jquery?
I’m trying to copy the contents of var ip, but I can’t. This is my code: $(function(){ $("#ip-server").click(function(){ var ip = 'ip.exemplo.com'; /* <-- Esse é o conteudo que quero copiar */…
-
1
votes1
answer115
viewsJquery is returning Undefined to one of the generic properties I created
Jquery is returning Undefined to one of the generic properties I created, to use with Bootgrid. I’m trying to load a modal according to the event click one of the buttons on the grid, but the modal…
-
1
votes1
answer38
viewsInsert a checkbox within a Jquery Javascript button
I have a list with a mousedown within each <li></li> and I need to put a checkbox within that li tbm only that the checkbox can’t have the mousedown. Is there any way to do it? <li…
-
1
votes1
answer40
viewsHow to recover variable value (custom Property) CSS?
For example, I have a variable defined in my style sheet: :root { --limite: 90vw; } To retrieve the value of this CSS variable in jQuery in such a way that each time this resolution changes (yes, it…
-
1
votes1
answer29
viewsHow to select all existing images and add an attribute to them
So I’m trying to select all the existing images and I came to develop this code (function ($) { var elementsImg = document.getElementsByTagName('img'), len, i; for (i=0, len=elementsImg.length;…
-
1
votes1
answer105
viewsSplit "100000000000" in JQUERY
I need to separate all the characters of a string into an array, and I have a problem, my code is the following var PISCampos = campos.split(""); When sending fields in the variable the following…
-
1
votes1
answer80
viewsEnable/Disable input text with via loop
The intention is, to put all text inputs of the variable VesaoNova Disable whenever text input VersaoAntiga is empty. The problem is in jquery in the conditions,? <?php while($row =…
-
1
votes1
answer26
viewsGif loading while function runs
I need to place a gif load while a function performs. The function simply changes the value of various products, when the user clicks the gif button should appear and when the inputs are filled it…
-
1
votes1
answer39
viewsHow to remove the " n" with jQuery?
I have a variable that receives the following content: dadosP.formapgto = $('input[name=opcaoPagamento]:checked') .parent().text(); But I get some \n inside that string, as follows Which also…
-
1
votes1
answer39
viewsUse Parent with input -- jquery
I am trying to recover the id of a parent div of an input <div id="parentDiv"> <input type="text" onfocus="mostra(this)"> </div> Using the onFocus function, it returns me Undefined…
-
1
votes1
answer1742
viewsAutomatic image upload without refresh
Colleagues. I am wanting to implement on my system, an image update as occurs on facebook, where we click on the existing image and select from our computer the desired image and the image is…
-
1
votes0
answers17
viewsHow to prevent different users from seeing the same information?
I made a form in which the user informs a client code and makes a search in a database, which returns the information of this client in the same html page of the form. However, if another user…
-
1
votes2
answers881
viewsFormat data dd/mm/yyyy in a jquery Datatable.net
How I format that date 2016-10-23T20:30:01.017 in one Datatable.net in the Brazilian format dd/mm/yyyy ? Controller: This relevant snippet of the code is where I populate the object that is in the…
-
1
votes1
answer566
viewsListing the return of a Viewbag for View?
Following the instructions of this post (Return the data to the View using Json.net or javascript-Asp.net mvc) answered by Loudenvier was like this: Class: public class TB_RECEBE_IMAGENS { public…
-
1
votes1
answer26
viewsscript only in visible tags
I want the script to count only tags <li> which are visible, but the code below counts even with display:none. Is there anything that can do that? I have the following HTML: $( ".rodapeUlCat"…
-
1
votes1
answer87
viewsFind the first tag after a class name and change it with jquery
I’d like to identify the first class='active' in my html and after adding a value in the element class <ul> but only the first <ul> My HTML <aside class="navigation"> <nav>…
-
1
votes1
answer504
viewsRetrieve data fields array() jQuery
I have the following fields in array(): <form enctype="multipart/form-data" id="enviar" method="post"> <table class="table" style="border-top: 1px solid #FFF !important;"> <tr>…
jqueryasked 8 years, 1 month ago Sr. André Baill 6,946 -
1
votes1
answer765
viewstraverse array and insert break line jquery
This application does not work as expected. var storeElements = []; var store = []; $('body').on('click', 'a.add_aluno', function () { var aside = $(this).parent().parent().children('aside');…
-
1
votes1
answer862
viewsChange comma height and width with mask
I have a code that calculates the amount of rolls needed according to the width and height of the person’s wall. Currently the code for the mask of the comma is this: $('.virgula').mask('####00,00',…
-
1
votes2
answers660
viewsReturn getInstallments Pagseguro
The getInstallments Pagseguro serves to return the amount of installments and the value of each installment, when informing a card and the value of the sale. The return I get is this: In this return…
-
1
votes1
answer94
viewsHow to ensure that an element will have the DOM event?
Good afternoon, Today I am facing a rather strange bug in my application: I have a textarea field where I type a body of email and just below it a button that when clicked obtains the content of the…
-
1
votes2
answers406
viewsMenu link color changes when scroll is over its respective section
Hello, everybody! Which Javascript code should I insert so that when the user is browsing (scrolling) over some section the "li a" receives a new class so that the color of the link is changed?…
-
1
votes2
answers310
viewsShow or Hide modal with sessionStorage
I was searching for a way to limit the appearance of a modal on my site, for example when clicking on a link asks for the e-mail registration before going to the anchor, but I do not want this to…