• table sorter / Jan - Dec

    Please help, my table is still sorting a-z, I would like to sort Jan - Dec my parser:  $.tablesorter.addParser({ id: 'monthYear', is: function(s) { return false; }, format: function(s) { var date = s.match(/^(\w{3})[ ](\d{4})$/); var m = date ? date[1] + ' 1 ' || '' : ''; var y = date && date[2] ? date[2] || '' : ''; return new Date(m + y).getTime() || ''; }, type: 'Numeric' }); my call: $('table.tablesorter').tablesorter({ headers:
  • autocomplete

     I am having problems with autocomplete. All the suggestions are coming out as one line. Eg ANOTHERTESTTEST instead of ANOTHER TEST the Test underneath. This is in company.php to get the selection if (trim($Msg) == "") {                    $term = StrippedChars($_GET['term']);             $sqlstring = "SELECT * FROM companies where name like '%" . $term . "%'";                                                    if (!($result = @ mysqli_query($connection, $sqlstring))) {                 $Msg = "An
  • rest api azure devops

    Hi, I'm really struggling to get the authenication header to work, to access my azure devops. I've tested the path and the Personal Access Token (PAT) with powershell. Everything works.  I just cannot get the same to work in javascript/jquery. Please see my code below. I've put down two different ways I've tried and commented it them out. would really appreciate the help. // var username = "username"; // var password = "54--PAT-TOKEN--xq"; var vstsAuthHeader = { "Authorization": "Basic " + btoa("" + ":" + "54--PAT-TOKEN----xq") }
  • column not directly summing

    i have dynamic table i want to update total, but total only summing old row ( not include new row ) <table id="so_data" class="table table-bordered table-hover"> <thead> <tr class="kop"> <th class="text-center" style="width:50px;">Code</th> <th class="text-center">Description</th> <th class="text-center" style="width:100px;">Qty</th> <th class="text-center" style="width:30px;">Unit</th> <th class="text-center" style="width:100px;">Price</th> <th class="text-center">Total</th> <th class="text-center"
  • strange jquery behavior

    I use jquery http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.js Also use this https://cdn.jsdelivr.net/npm/pjax@0.2.8/pjax.js I try to use ctrl+click but it not work debugger show that first run pjax, then jquery line 4291 here code return typeof jQuery !== strundefined && (!e || jQuery.event.triggered !== e.type) ? jQuery.event.dispatch.apply( eventHandle.elem, arguments ) : undefined; I replace line jQuery.event.dispatch.apply( eventHandle.elem,
  • toggleClass Fade effect not working with display:none/block.

    $('.item a').click(function() {     $('.mydiv').toggleClass('displayit', 5000); }); So I've created div with display: none, and jquery that adds display:block (.displayit) when I click on .item a (link). Now, I want to  add fadein and out to toggleClass but it's not working. I added jquery-ui.js and it still does not work.
  • showing data in modal on click button not working

    <!-- Main content --> <section class="content"> <div class="row"> <!-- Left col --> <section class="col-lg-12 connectedSortable"> <table class="table table-striped table-bordered data display nowrap" style="width:100%" id="data"> <thead> <tr> <th>Code</th> <th>Description</th> <th>Category</th> <th>Merk</th> <th>Qty</th> <th>Price</th> </tr> </thead> <tbody> <?php foreach($stock as $s) { ?> <tr> <td><?php echo $s->code ?></td> <td><?php echo $s->description ?></td> <td><?php echo $s->Typename ?></td>
  • Sortable and drag speed issue

    I have a jQueryUI sortable list. I need to keep track of each new index of the element while dragged, based on the "change" event. But it only works reliably from slow, up to normal drags. If the user drags the element quickly, the "change" event loses track of some indexes with no error thrown in the browser's console.  Here is a jsFiddle that shows the problem:https://jsfiddle.net/yhp3m6L8/2/ In this jsFiddle, you can drag an element and see its index change. Below the list, there's a console emulation
  • JQuery Image Carousel Animated Roundabout Stopped Functioning

    Hi guys, I have a JQuery roundabout on the home page of my site. It stopped functioning recently, and I'm attempting to fix it. I would greatly appreciate any help trying to resolve this issue! Here is the web page where it's malfunctioning: http://www.birkeloart.com And here's the code for the page: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en-US"> <head profile="http://gmpg.org/xfn/11">
  • Autocomplete hidden a part of response

    Hi , sorry for english thi is a part of my function to get response of autocomplete : $arr_result[] = $row->comune.' ('.$row->sigla.') <span style="display:none;"> ['.$row->id.']<span>'; echo json_encode($arr_result);                                                                                                                                             in my input field i want hide the value in the span but the response is : Alzano Lombardo (BG) <span style="display:none;"> [1934]<span> HOw can
  • load div after div after div ...

    Hi,  I have a galery of n photos (could be 1000, 2500 or 5000). I would like to load all the images names in one page with a loader image for each name. I can have 2500 names for example, with 2500 times the same loader. And after, I would like to replace the first loader with the jpg of the first image. As soon as the first jpg is loaded, the script replace the second loader with the image of the second images, and so on. The goal is to load all the images names in one time and after, to load all
  • Highlighting the cell on character (.) input only

     I have this jquery code to highlight the table cell when a number is entered. I need highlighting only when a dot (.) is entered in the cell only. So when a dot (.) is entered in the cell, the highlight will take place, other times not. here is a fiddle example. http://jsfiddle.net/k6p3ecL5/ thank you for your help. html:  <table>     <tr>         <td>             <input type="text" class="number" />         </td>         <td>             <input type="text" class="number" />         </td>     </tr>
  • conflict between two javascript

    <script> window.onscroll = function() {myFunction()}; var header = document.getElementById("nav-main-container"); var sticky = header.offsetTop; function myFunction() {   if (window.pageYOffset > sticky) {     header.classList.add("sticky");   } else {     header.classList.remove("sticky");   } } </script> <script> var parallax = document.querySelectorAll(".parallax"); var speed = -0.25; window.onscroll = function() { [].slice.call(parallax).forEach(function(el, i) { var windowYOffset = window.pageYOffset,
  • showing total in table

    please help, cannot sum table column. this is my code : <div class="content-wrapper" > <!-- Content Header (Page header) --> <section class="content-header"> <h1> Customer List </h1> <ol class="breadcrumb"> <li><a href="home_admin"><i class="fa fa-dashboard"></i> Home</a></li> <li class="active">Vendor - Customer</li> </ol> </section> <!-- Main content --> <section class="content"> <!-- Small boxes (Stat box) --> <!-- /.row --> <!-- Main row --> <div class="row"> <!-- Left col --> <section class="col-lg-12
  • on load img hide div

    may i know how other div hide when feature image load
  • jQuery Audio Time Duration Change on Slider Click

    I noticed that the following code runs fine on desktop & laptops, but not on my Android mobile or other mobile devices, to change the duration of the song when user clicks on the slider: <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <div id="timeline-box"> <input id="seekslider" type="range" min="0" max="100" value="0" step="1"><br> </div> **//jQuery to detect when user changes the timeline with the seekslider $(document).ready(function(){ $("#seekslider").mouseup(function(e){
  • Qunit testcase I want run through build.xml

    Hello, I am new in qunit. I have setup initial setup for the qunit testcase. which are run fine when I open the browser. But I want to same test case while I deploy the code in specific env. I have build.xml file where I have setup other java UNIT test case to run as part of the deployment. does anybody have setup to run test case from build file. One more question, I have install qunit in my system. I have try to run through cli. I am getting the error. which I have attached the screen shot. Thanks,
  • Jquery-UI - Drop Sound Not Playing Properly on iOS

    I've set up a codepen here: https://codepen.io/nolaandy/pen/eXeZYK If I drag an image from one drop zone to a different drop zone above, I don't get a sound on iPhone/iPad on the initial drop. Only If I drop an already dropped image in the same spot will it make a sound on iPhone/iPad. Other than this I get sounds perfectly on all browsers, even ie/edge. Any help would be GREATLY appreciated.
  • When I click on accordion, it make my page scroll down

    Hi - I'm using this accordion script http://jqueryui.com/accordion/#default, which works great.  But whenever I click on one of the buttons to reveal the info in it.  It makes the webpage scroll down. Is any way to fix that?  Thanks a ton - Eric
  • autocomplete Uncaught TypeError: Cannot use 'in' operator to search for 'length' in []

    Hi, this is my js: $('#autocode' + num).autocomplete({                     source: function (request, response) {                         console.log(request)                         $.ajax({                             method: 'POST',                             url: '/retrieveProducts',                             data: {                                 term: request                             },                             success: function (data) {                                 console.log(response(data));
  • Future of jQuery Real Time Data

    Will jQuery every make something for real time data effecting. Am not talking about Ajax request. As Ajax does some short stuff but we have to add time interval to refresh page. Which I think is making too many unnecessary requests to sever. To which we want the data should effect only when the server side is effected in same time in all device. I know there are alternatives but will jQuery bring this kind of change in future or not?
  • Refer to nested text pattern not working? Problem ::after tag

    Assume I have (simplified) the following code: <div ...> other text to keep <div  ...> <p> <em> <a ....> .....foobar.... </a> </em> </p> ::after </div> </div> How do I remove all (ONLY !) innermost <div> which contain the pattern "foobar"? Since ::after comes after the target elements it should not be relevant. correct? $("div:contains('foobar')").eq(($("div:contains('foobar')").length) - 1).css("display", "none"); does not work
  • Link manipulation (DOM-based) - JQuery Mobile

    Hi all,  we use jquery.mobile-1.4.5.min.js in our application. Burp scan found a Link manipulation (DOM-based) vulnerabilitiy in JQuery Mobile sources: Link manipulation (DOM-based): Issue detail The application may be vulnerable to DOM-based link manipulation. Data is read from location.pathname and passed to the 'href' property of a DOM element via the following statement: e[0 ] .href= g|| location.pathname from : return e.length?g=e.attr("href"):e=f=a("<base>",{href:d}).appendTo("head"),b=a("<a
  • how to add a child node?

    hi all based on this sample: http://jsfiddle.net/jamiguel77/Lfy2bc7t/34/ how to add : 1) Final Node? 2) Right Node? 3) a Node? my Root Node is (+) here the start code: http://jsfiddle.net/jamiguel77/9vmugf5r/12/ thanks
  • data-application font of an external script only used for the first display

    Sorry for my English I test on MacOs 10.13.6 and Safari 12.0.3 I write a multipage web app with only one query mobile file : main.html All the js and css files are in the head (see below). 2 pages are dynamically updated with : $(document).on('pageshow','[data-role="page"]',function(event){   switch(event.target.id){     case 'dictee' :       ...       $(document).ready(function(){         call to abc2svg-1; // external script       });       ...       break;     case 'correction':       ...    
  • Re-opening selectmenu programatically is triggering the select event undesirably

    I'm use mouseenter and mouseleave events on the container element to trigger the opening and closing of selectmenu. But somehow the re-opening is triggering the select event undesirably. I don't want the select event to be triggered when I re-open the selecemenu. Here is how to reproduce the issue: Move mouse cursor onto the selectmenu button, and the selecetmenu will open automatically. Move mouse cursor onto random options. Move mouse cursor out of the selecemenu, and the selectmenu will close
  • Displaying an Image Link for a Limited Time

    I'm trying to get an image link to display for 24 hours on my site. This is what I have so Far, what am I doing wrong? <script src="http://code.jquery.com/jquery-1.8.2.min.js"></script> <script type="text/javascript">  window.setInterval(function(){         var current = new Date();         var linkOneStartDate = new Date("March 6, 2019 12:57:15")         var linkOneExpirationDate = new Date("March 7, 2019 12:58:00")  if (current.getTime() > linkOneStartDate.getTime()) && current.getTime() < linkOneExpirationDate.getTime())
  • How give the default site after a date selection

    Good day all I am complete a small application with jquerymobile. On a page, I add a tab with the possibility to select date. On a smartphone, after selecting a date, the browser get a bit large when the date can be select. When it's done, I click on close button to close the panel. The problem is after the browser keep the same size and I have with my finder make the correct size. Is there a way to tell to jquerymobile or whatever, the give the default size?? Many thanks
  • How can I correctly add the lib with jqueryUI

    Good day, I spend a lot time to make my jquery mobile web site, and I particularely spent time to understand with the jquery UI, change my layout. I need to add a datepicker, this is the reason why I added (only because the datapicker layout) <script src="js/jquery-ui-1.12.1/jquery-ui.js"></script> <!--    <link rel="stylesheet" href="css/jqueri-ui-1.12.1/jquery-ui.css">--> But since I uncomment the jquetyui CSS file, the content of my web site change. Then I wonder how can I use it. Is there a way
  • Tabs Widget possibility of Prev/Next buttons

    Using a standard JqueryUI Tabs widget is there a reasonable way to create buttons on each tab to go prev/next among the tabs? I am creating pages with several tabs for user input. I would ideally like to enable the user to have prev/next buttons; additionally, I would like to add the tabs they have visited to a collection so that when they go to click "Submit" code can direct them to the first tab of the page not in the collection of visited tabs.
  • rounding to 2 decimal places

    i have a little script that counts the total of a column in a table $(function () { var TotalCoreProd = 0; $("[id*=col01]").each(function () { TotalCoreProd = TotalCoreProd + parseFloat($(this).html()); }); $("[id*=TotalCoreProd]").html(TotalCoreProd.toString()); }); problem is, it's outputing the value with about 20 decimal places. i need to round this to 2 decimal places. i believe ".tofixed(2)" should be used, but no matter where i try and place it, it ends up causing the code the fail completely.
  • Ajax POST not successful

    I'm trying to create ajax script where the user clicks a button e.g. Product Type Alpha Product Type Beta It then sends that response via ajax to a new page and remembers what the user selected but now asks more questions. I'm trying to do the first stage, but having no luck; jQuery(document).ready( function($) {     jQuery('.sectors .sector_btn').click(function() {         var myVar = jQuery(this).attr('name');         jQuery.ajax({             type: 'POST',             url: location.origin + '/filter-page/?product_type='
  • check each LI has a class "selected"

    Hi, I have a UL LI <ul class="selections">     <li class="check-option ok selected">         <div class="selections-text">Ok</div>         <div class="selections-icon"><img src="/img/icons/check-tick.png" class="check-icon"></div>     </li>     <li class="check-option">         <div class="selections-text">Advisory</div>         <div class="selections-icon"><img src="/img/icons/check-circle.png" class="check-icon"></div>     </li>     <li class="check-option">         <div class="selections-text">Defect</div>
  • jQuery ajax, a bit confused

    I'm using jQuery 3.3.1. Reading through the page on .ajax() I was a bit confused on some things. Currently I'm using code like this. I stripped out some code to make it more readable. $.ajax({     method: "POST",     dataType: "json",     url: "includes/contactAjax.php",     data: { action: "getCompanyContacts", companyid:            $('#project_company').val() },     success: function (data) {     },     error: function (jqXHR, textStatus, errorThrown) {         console.log(textStatus + ' - ' +
  • Why won't this ajax post work

    I'm not getting any errors.. I get Start and End in my console log. $(document).on("click","#submitrfp",function(e){ console.log('Start'); var P = $( "#apurchase" ).val(); var L = $( "#alease" ).val(); $.ajax({                 method: "POST", url: "scripts/order-aircraft.php", data: { Purchase: P, Lease: L} }) .done(function(result) { console.log('>>' ); }) console.log('End'); });
  • Autocomplete source file

    Hello, I am trying to add the Autocomplete feature to my website. It works fine if I list my data right after the "source:" tag like below, $( "#tags" ).autocomplete({ source: ["Item 1", "Item 2"] But I would like to use a local file as the data source. When I put the same data in a local file and put the file name as the source as in the example below, the autocomplete does not work.  $( "#tags" ).autocomplete({ source: "data.php" Can anyone help me with my problem? Thanks, Todd
  • Making Fields Required in this Google Forms Submitter Script

    Hi, I came across the following script - and it's been awhile since I looked at and don't remember where I came up on it. GitHub I believe. At any rate, I was revisiting it and I need some help. The form submissions work. When someone fills out the form results go to the Google Form as anticipated. However, none of the fields are currently required. That's what I need help with. Where in the following script would I check if certain fields were filled out and report back to the user on submit? And
  • button only activates after second click

    I am not sure why that when I click my button it only opens the next page by double clicking, I need this to be a single click HTML <div class="button mover" id="contact" data-href="{{ contact_link }}" data-toggle="tooltip" data-placement="top" title="go to our contact form" id="contact_ultra">CONTACT ULTRA</div> JQUERY var touch_contact_start = false; $("#contact").on("click touchend", function(){ {% if app.config.mode == 'dev' %} console && console.log("touchstart on contact
  • Set a cookie for addClass and removeClass

      $(".div1").click(function (e) {       e.stopPropagation();       $(".div2").removeClass("active");   }); How I can set a cookie so I don't have to remove class all the time? I want it to be hidden even after reload.
  • Background color won't reset after mouseOut

    Hello, I've my portfolio online here http://mircofragomena.com As you can see every time you hover on a menu item the background changes, but on mouse out the background won't go back to the original one, but keeps the color of the last hovered item. It's the only bug so far and I'd like to fix this as I'm jobless and I've to share my portfolio with clients and companies :D This is the JS that changes the background color, and should bring it back to its initial one on mouse out: $(function() { //
  • 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