// Set the value of the current page URL to the input element with ID 'current-page' document.addEventListener('DOMContentLoaded', function() { document.getElementById('current-page').value = location.href; });