Опрыскиватели бензиновые

$( function() { $( "#slider-range" ).slider({ range: true, min: 32990, max: 49990, step: 1133, values: [ 32990, 49990 ], slide: function( event, ui ) { $( "#amount" ).val( "$" + ui.values[ 0 ] + " - $" + ui.values[ 1 ] ); } }); } ); $("#slider-range").on("slide",function(event, ui){ $(".button-box").addClass("change"); $(".price-min").html(ui.values[0]); $(".price-max").html(ui.values[1]); sort = window.location.search.match(/(name=ASC|name=DESC|price=ASC|price=DESC)/); sort = (sort !== null ? "&"+sort[0] : "") $(".button-update").attr("href",window.location.pathname+"?price_min="+ui.values[0]+"&price_max="+ui.values[1]+sort); }) function sorting(name,this2){ filter = window.location.search.match(/(price_min=[0-9]+&price_max=[0-9]+)/); sort = name; sort += "="+($(this2).attr("sort") == "none" || $(this2).attr("sort") == "DESC" ? "ASC" : "DESC" ); window.location = window.location.pathname+"?"+( filter !== null ? filter[1]+"&" : "" )+sort; }