Using document.ready instead of window.onload to set up nexus elements

no more overwriting of the body.onload or window.onload function.