jQuery(function ($) { document.body.appendChild(chimpPopupLoader); $(window).load(function () { document.body.appendChild(chimpPopup); }); });