skip to Main Content

jquery and sort function not working in chrome but works in firefox?

i use a javascript routine with jquery3.6.1 to order divs as follow when the button #tri is clicked: $("#tri").click(function() { var $divs = $("#resultats div.notice"); var alphabeticallyOrderedDivs = $divs.sort(function (a, b) { return $(a).find("div.bibloc:first").text() > $(b).find("div.bibloc:first").text(); }); $("#resultats").html(alphabeticallyOrderedDivs); }); the…

VIEW QUESTION
Back To Top
Search