document.addEventListener("DOMContentLoaded", function () { document.getElementById("ua").innerHTML = navigator.userAgent; });