PageSourceSearch

https://www.poelediscount.com/modules/vatchecker/views/js/front.js

js poelediscount.com collected 2026-10-04 03:05:06 UTC 2,002 bytes, 1 lines download raw bytes

1jQuery(function($){var $document=$(document),checked={};vatchecker.validate=function(vat_number,id_country,$elem){$elem.removeClass("validated error text-danger text-success");$elem.next(".vat-result").remove();$elem.after('<div class="vat-result small"></div>');$result=$elem.next(".vat-result");if(!vat_number||vat_number.length<8){return}var $result=$elem.next(".vat-result"),loading=". . . ",loading_interval=setInterval(function(){if(20<loading.length){loading=". . . "}loading+=". ";$result.html(loading)},500);if(checked.hasOwnProperty(vat_number)){success(checked[vat_number]);return}$elem.css({opacity:"0.5"});$.ajax({type:"POST",url:vatchecker.ajax_url,headers:{"cache-control":"no-cache"},data:{vatchecker:vatchecker.token,vat_number:vat_number,id_country:id_country},dataType:"json",success:function(resp){success(resp)}}).always(function(){clearInterval(loading_interval);$elem.css({opacity:""})}).fail(function(resp){clearInterval(loading_interval);$result.remove();$elem.addClass("error text-danger")});function success(resp){clearInterval(loading_interval);$result.html("");if(resp.hasOwnProperty("valid")){if(true===resp.valid){$elem.addClass("validated text-success");$result.remove();checked[vat_number]=resp}else if(false===resp.valid){$elem.addClass("error text-danger");if(resp.hasOwnProperty("error")&&resp.error){$result.addClass("text-danger").html(resp.error)}}else{$elem.removeClass("validated error text-danger text-success");$result.remove()}}else{$elem.addClass("error text-danger");$result.remove()}}};$document.on("blur",'[name="vat_number"]',function(){var $vat=$(this),$form=$vat.parents("form"),$country=$form.find('[name="id_country"]'),val=$vat.val().toUpperCase().replace(/[^A-Z0-9]/gi,"");$vat.val(val);vatchecker.validate($(this).val(),$country.val(),$vat)});$document.on("change",'[name="id_country"]',function(){var $country=$(this),$form=$country.parents("form"),$vat=$form.find('[name="vat_number"]');vatchecker.validate($vat.val(),$country.val(),$vat)})});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.