Wybierz kategorię wniosku

window.onload = function() { var anchors = document.querySelectorAll('.custom-icons a'); for(var i = 0; i < anchors.length; i++) { var anchor = anchors[i]; let url = new URL("https://gminaleszno.pl/pos/file_catalog/"); url.searchParams.append('file_category', anchor.getAttribute('catid')); url.searchParams.append('title', encodeURI(anchor.innerHTML.replace(/]+>/ig,''))); anchor.setAttribute('href',url); } }