Answers for "fire off some javascript on page load"

0

fire off some javascript on page load

document.addEventListener("DOMContentLoaded", theDomHasLoaded, false);
window.addEventListener("load", pageFullyLoaded, false);

function theDomHasLoaded(e) {
    // do something
}

function pageFullyLoaded(e) {
    // do something again
}
Posted by: Guest on August-28-2020

Code answers related to "fire off some javascript on page load"

Code answers related to "Javascript"

Browse Popular Code Answers by Language