• Collapsible widget div too wide

    Hi, i have some collapsible widgets and i noticed they are a little more wide than buttons using the ui-btn class: https://theredlips.digitalking.it/giochi/index.html I tried one solution found on Stack Overflow but seems not working .Collapsible, .Collapsible h4 {     display: inline !important; } .ui-btn-inner {     white-space: normal !important; } Have suggestions so i can have all the elements exactly the same width? Thanks!
  • How To Control Input Type Dropdown Select Options Menu With Jquery

    I am creating a web site. In this web site , there is a form. I have added 3 dropdown menus in this form like below. Now I want to when someone selects the number 5 from Adults menu , I want to show number 5 in the infants menu. And also I want t keep Adults + Children = 9. Then if this Total is below than 9 , I want to show that extra number in the infants menu. I mean like this , Adults + Children = 9 Adults = 5 and infants = 5 But , Adults + Children = 8 Adults = 5 , Children = 3 , it means there
  • Not submitting state or province from other picklists

    I have a form that displays a select box for state or province (HTML name="state") depending upon what country is selected. For example, when United States is selected from the 'Country' select box, all the US states appear in another select box called 'States'. When Canada is selected from the 'Country' select box, all Canadian provinces appear in another select box. This is also the case for several other countries.  The issue is this, when submitting, say United States and Colorado, the submission
  • Swipe right to toggle class but only if not swiping over specific classes

    On my site I toggle classes to show the mobile navigation. Next to the button I offer the possibility swipe right to open the navigation and swipe left to close it again, but i have trouble with my tables. For big/long tables I am using overflow: auto which makes those tables scroll able(right & left if the content doesnt fit). Now if I like to scroll them, the navigation gets open.  I tried something like that: jQuery: $( 'body' ).on('swiperight', 'body:not(.outertable)', function(){     if($('.nav-toggle').hasClass('is-active'))
  • disable past dates in datetimepicker

    I'm using datetimepicker with bootstrap 4 and I want to not be possible to select past dates so I have the minDate like: $( ".input-group.date" ).datetimepicker({     format: "dd MM yyyy - hh:ii",     autoclose: true,     todayBtn: true,     minuteStep: 5,     minDate: 0 }); But its not working, the user can select past dates. Do you know why? I have a fiddle with the code "https://jsfiddle.net/0y8k9ah5/1/", but don't know why the datetimepicker is not working in the fiddle.
  • How to open multiple Accordions in print view

    I am currently trying to use this CSS to display accordion style column/headings as "open" when in print view. However it is not working and the headings are still closed in print view. Please let me know if you have additional questions. Here is another person's example of the goal Im trying to reach.  The first picture is before: Before and second is end goal for print view: end goal Any advice or tips are welcome <div id="accordion"> <div class="card"> <div class="card-header" id="aheading">
  • how to capture jquery keyboard paste event (Ctrl+V)

    how to capture jquery keyboard paste event (Ctrl+V) and how to get the pasted value
  • _doPostBack not firing in Firefox

    Team, We have migrated our jQuery to 1.6.3 to 3.3.1 which has led to browser issues.  1) _doPostBack :  The below code works fine and post backs to the event in Chrome, Edge, IE but not in Firefox. I'm not getting any error messages as well. However, when I remap jQuery to 1.6.3 post back is triggered. Not sure what the issue is.  __doPostBack($('div.tree-view input.update-button').attr('name'), 'ItemChecked')  Any helps would be helpful.  Thanks, Prasenna
  • How to pass variable values from jquery function to css file

    Hi All, I am using jquery-ajax function to call database on page load and display values on front age(html page). My database contains coordinates also where value should get displayed. How can i pass variable values from jquery function to css file. JQuery function code: function callme() {     $.ajax({//create an ajax request to display.php         type: "POST",         url: "ReadDataBaseValue",         dataType: "html", //expect html to be returned                         success: function (response)
  • Next and Previous buttons in jquery image gallery

    I want to code the next and previous buttons for my jquery image gallery. When i click on next button, it shows me the first image of the gallery and then it stops working for any other image. Can someone help me what i am doung wrong in my code? Please help? Below is jquery. <script type="text/javascript">         jQuery(document).ready(function () {             jQuery('.item').click(function () {                 // Getting "src" attribute of the image that was clicked.                 var path
  • Make controlgroup radio button look like buttonset

    Is there a way to remove the circle in radio buttons used in controlgroup? I'd like to upgrade from 1.11, but it suddenly makes all of my old buttonset radio buttons much larger and uglier :)
  • How to Make jQuery UI Slider Smoother when the Step is 0.25

     I know that we can change the step in short distance between min and max and Math round the UI value to create smooth sliding like step: .0001, ... $(".value").text("slider value: " + Math.round(ui.value)); but this is Ok when the step is 1. How about this case which is 0.25. Can you please let me know how to make the slider smooteher $( function() { var handle = $( "#custom-handle" ); $( "#slider" ).slider({ min:-12, max:6, step:0.25, create: function() { handle.text( $( this ).slider( "value"
  • use .done in place of complet.

    hi Deprecation Notice: The jqXHR.success(), jqXHR.error(), and jqXHR.complete() callbacks are removed as of jQuery 3.0. You can use jqXHR.done(), jqXHR.fail(), and jqXHR.always() instead. my doubt is does the above stmt says that follwing way of using  will be depricated        $.ajax({             url :"views/departments/create.cshtml",             datatype: "xml",         success: function( data ){             alert(data);         },         global :true,         error : function(data){            
  • Ajax redirect if return false

    I have all the code done for the login and session done now I want on each page that requires the user to be logged in to check and if false redirect. class.php     public function check_session() {       session_start();       if (isset($_SESSION['user_id'])) {         return true;       }       else {         return false;       }     } session.php <?php       /* Includes */       include 'database.php';       include 'class.php';       $session = new Session($pdo);       if($session->check_session())
  • Migrating jQuery 1.6.3 to 3.3.1 and browser issues.

    Folks,   As part of our remediation activity for vulnerabilities reported during pen test, one of the issue reported for "Outdated software may contain known vulnerabilities." and suggested us to migrate the jQuery from 1.6.3 to 3.3.1 and we had migrated the jQuery using nuggets in our .NET environment. This has opened up few issues as below, Issue 1 : Prior migration with jQuery 1.6.3 – In a web page, a user can select only one checkbox, when the user selects another check-box, already checked-one
  • Call function on page load and onchange

    I want this function to check the state of the checkbox on load as well as onchnage but it doesn't work, what am I doing wrong please?:             $(function (SFToggle) {                     $('#short_format').change(function () {                         if ($('#short_format').is(':checked')) {                     $(".no-short-format").hide();                         }else{                     $('.no-short-format').show();                         }                           });             });    
  • showing an alert when the element is dragged and placed outside of parent

    Hi, I am using jquery UI to make the soting but i am missing a piece of information here when >>  1. i want to move the childrens which are inside a parent - works cool  2. I cannot move childrens to different parent, i should be able to show an alert message: - This is not working  Here is my Code:  $('tr.childrow').mousedown(function() {     var rowID = $(this).data('answer-id');     siblingRow = $('tr.childrow[data-answer-id=' + rowID + ']');     /* Hide rows that should not be sortable */    
  • How to make a line move above the hovered menu item?

    I am trying to make the red line move above the hovered menu item, then disappear when no menu item is selected. I am very new to Jquery so really stuck on how to do this. Does anyone have any ideas? The code is at http://jsfiddle.net/xpvt214o/276727/ HTML <div class="topnav" id="myTopnav"> <a href="#home" id="homeLink" class="active">Home </a> <div class="dropdown"> <button class="dropbtn">About <i class="fa fa-caret-down"></i> </button> <div class="dropdown-content">
  • properties name case-insensitively in jqgrid

    How do I ignore properties name case-insensitively with jqGrid? For column name i want uppercase in my data.for label lft rgt. https://jsfiddle.net/99x50s2s/851/
  • Post bock inside a third nested accordion panel will shifts to top 1 child panel

    Hi All, I need some help regarding jQuery Accordions. i have developed an .Net web application using jQuey and CSS, application format looks like below <div class="accordion">       <asp:Repeater ID="repAccordian">              <h4 style="text-decoration: none">                   .......              </h4>       <div>             some asp controls             <div class="accordion">              <asp:Repeater ID="repAccordian1">              <h3 style="text-decoration: none">                   .......
  • Want to call servlet

    Hi All, There is a requirement to get image coordinate as image is clicked. At the same time, it should call the servlet by taking that image coordinates. Currently it is showing the coordinates on image click but not calling servlet.
  • how to return data from function to jquery function

    i have 2 ajax jquery method,which call two indepent different function and return different data,but on showing datain gridview in jquery they sometime showing same data, may be during return data i m doing something wrong. <script type="text/javascript">     function consultantchat() {         $(function () {             debugger;             var r = document.getElementById("<%=txtmanagerid.ClientID%>").value;             var s = document.getElementById("<%=txtconsultantid.ClientID%>").value;  
  • Find count of occurrences of a key in an array that appears only once?

    Hi i have the following array test ={  [id:1,subject:math],  [id:2,subject:math],   [id:1,subject:science],   [id:3,subject:science], } how can I find the key that appears only once like..  [id:2,subject:math] , [id:3,subject:science]. I need to output the key id value 2 and 3. Thank you
  • Find a match in two dimensional array?

    I have an array in the following format. test =[  [id:1,subject:math],  [id:2,subject:math],   [id:1,subject:science], ] what i basically want is when i am trying to push a new object in my array , i should check if the id subject pair already exits like [id:1,subject:math] should be inserted. So basically unique pairs are only to be allowed. Hwo can i loop through this test array to find if a match exits. Thank you in advance.
  • What event to use to call taphold?

    I'm technically using a separate script for taphold instead of jQuery Mobile, but when I tested with JQM I had the same problem. I have a page (infinite scroll) with potentially 2000+ elements. I want the user to be able to taphold any one of these elements to run an Ajax script. What is the proper event to use in order to trigger the taphold? Here is my code: function holdClick(id, username) {   $('#list_' + id).on('taphold', function(e) {     alert('worked');     // I tried removing the following
  • change handler function issue

    Hi All, We have text box control[actualTwo] has below functionality, we see issue in production even actualTwo has value, sometime deltaTwo been set to blank, This issue happen inconsistently only for few users, we don't have option to connect users, we are not able to reproduce the issue.  how can we reproduce the issue. Browser : IE 11. My suspect,actualTwo control has change event handler twice if any reason 2nd function ignores execution, deltaTwo will have blank value, is this case can happen,
  • Detect multiple presses of the same key

    I'm trying to detect how many times a key is pressed. I'm trying to set up an old phone type of keyboard, so if I press 2 once I get "A", if I press 2 twice I get "B" and if I press 2 a third time I get "C". This is what I have so far, but it's not working properly. The console shows no errors, but if I press 2 twice it alerts A twice instead of B, if i press 2 three times it alerts A three times instead of C. var abcKey = 0; $(document).on('keyup', function( e ){   if(e.which==50){         // Keyboard
  • Displaying content when checkbox is checked

    What is the best way to display additional content when only the first of a series of checkboxes is checked. For example, the form below includes four checkboxes. When the first is checked, a question with a textarea field needs to appear. <div class="checkbox">     <label><input name="answer" id="answer1" type="checkbox" value="Answer 1">Answer 1</label> </div> <div id="whyContainer" class="form-group hidden">      <div>         <label class="control-label" for="expertise">Why?</label>     </div>
  • Communicating between two pages using jquery and ajax

    Hi I am trying to pass data, namely through query strings, using jquery and ajax between two php files: In ecovib2d_adriant.php (calling program):-jquery in function changePic $(document).ready(function(){ $.(“Graphic_select”).change(function{ $.post(“watermark.php?Pic=“ + picname + “&Person=“ + personname); $.send(); }); }; In watermark.php: I get picname and personname via the query string and then put a watermark on the image and then construct a query string using ajax to pass back to ecovib2d_adriant.php
  • Performance problems

    Hi, I'm quite a newbie in jQuery and i've made my first real script to show results of a mysql query (with php) in a <div> below the search form. It works quite well but when I have more than 50 results, browser bugs and stops and when I make 2 links or more, it refreshs the page but don't execute the script. My script isn't probably very clean and I look for someone to help me optimize it. Thanks in advance.
  • swipeleft breaks, inline elements become blocks, when using jQuery 3.3.1 and mobile 1.4.5

    When I try to use the stable releases of jQuery and jQuery Mobile, I'm having 2 specific problems: 1. The swipeleft feature stops working. No errors in the console, it just doesn't fire. Changing jQuery to 2.2.4 and leaving jQuery Mobile at 1.4.5 does work, though. 2. All on my <input ...> <label ...> elements turn in to blocks instead of inline. The labels still show up inline, but there's an apparent break (and tab) after each <label>. And removing the <label> tags doesn't help, it just puts a
  • Passing result from Google distancematrix to each element in table

    Hello, I currently have a task that requires me to retrieve the distance between two selected drop-down locations and run them through Google's distancematrix API which returns a "distance".  I am then supposed to pass that distance value to a field in the table, but the caveat is that the table is dynamic and needs to allow for added rows if necessary. My current setup, I can pass the result to the t_mileage field, but the on change event passes the final value to all totals and not each. Here is
  • Prevent iOS keyboard push up

    Hello there, I'm creating my first App with Jquery and I don't want iOS to push my app up when someone click's on a input field. I have searched the web and appearently iOS changes the scrolltop position.  I have set the scrolltop to 0 when focus is on but my document is still being pushed. I've now created a workaround with a settimeout so my scroll position is restored to 0 but now you can still see the screen change position really quick. Does anyone know what event I can use so the scrollposition
  • jquery/ajax error capture

    Hi All, Need some help with jquery/ajax error trapping. During Ajax sometimes sql errors are being thrown to front end & sometimes not. Could you pls let me know how to debug php from ajax calls by having some trace dumps, handle error try catch  Thanks Sri
  • Using EditUrl To Post Data

    I'm working with a legacy code and it's giving me a hard time as I cannot figure out how data are being passed from jqgrid to a method on the server. The server method signature is as follows: public ActionResult ShowProductsDetails(string operation Product prod, string extraData) I noticed that the operation parameter is used to decide which action to use i.e. edit, delete, save. The prod parameter contains data from all the columns of the jqgrid.  extraData is an extra data that is set using edtitData.
  • Invalid characters

    Hi I am trying to check for invalid characters in two text areas in a form as shown below: 1. <textarea type='text' rows="10" cols="100" name="comment" maxlength="1000" id='comment' required /></textarea> 2. <textarea type='text' rows="10" cols="100" name="comment2" maxlength="1000" required id='comment2' /></textarea> I am checking for invalid characters via this jquery function: <script> $(document).ready(function Val(){ if (/[*?]/.test($('textarea').val()) { // do something alert("Invalid characters
  • jQuery awesomplete autocomplete plugin

    Hello,       This is not directly related to the jQuery autocomplete. I am using something similar that I have found a little simpler to use as far as initial set up goes. I have everything working but I am needing some guidance on how I can have a user type something into a search input, the user only sees the label if you will but upon enter or button click it takes them to the corresponding URL. My data structure example: { value: 'Google', env: 'Prod', url: 'https://google.com' } Expected result:
  • Jquery core and Jquery Ui version compatibility

    HI All, Can someone help me out how to find the compatible versions for jquery core and jquery UI? Any links would be helpful! Thanks!
  • How to insert hyperlink via jQuery

    How can I define a hyperlink as a variable and insert it into the a href using jQuery? The reason for this is that our lead management system is automatically appending all hyperlinks causing some of those with specific URL parameters to break. Here is what I have so far, which I know is a mess: <script> function linkHigh) {     var str = "high temps";     var finalLink= str.link("https://www.weather.com?bref=abcdefg#hightemps");     document.getElementById("highTemps").innerHTML = finalLink; } </script>
  • ui-icon-triangle-1-s missing

    I am using jquery.ui.combify to display combo boxes. In a test programme the south-pointing arrow is displayed as normal but when integrated into the live programme the arrow is missing even though the functionality works. I am guessing that I have a missing library or an old library. Any advice is appreciated. Thanks My header information is as follows:     <script src="includes/jquery-3.2.1.min.js"></script>     <script language='JavaScript1.1' src='scripts/ap-base.js'></script>     <script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.min.js"></script>
  • Next Page

  • Announcements

  • The Basics of jQuery AJAX

    A step-by-step tutorial for those new to jQuery and wanting to use AJAX in their projects. Includes valuable information about troubleshooting using the console and understanding the request / response. http://jayblanchard.net/basics_of_jquery_ajax.html
  • jQuery Conference 2010: Boston Announcement

      The jQuery Project is very excited to announce the jQuery Conference 2010: Boston on October 16-17, 2010.  The conference will be held at the Hilton Boston Logan in Boston, Massachusetts.  The best part of this announcement is that Tickets are on sale now!  This venue is the largest that the project has worked with to date (Harvard Law School in ‘07, the MIT Stata Center in ‘08 and Microsoft New England Research Center in ‘09) and we expect to sell out very quickly. A brief synopsis of some of