I fire my javascript using the onload property -> window.onload = function(){ // start code }
Rececently I started doing an .innerHTML write to the <head>
tag which sets my .js file.
document.head.innerHTML = html_string
// where html_string contains the link to my .js file.
Problem I'm having is that now the onload function is never called so my page has no javascript on it.
Is there a way to manually call it or emulate its behavior?