Thank you all.
Because there were two separate anonymous functions,
each with their own "onload()" function I thought it was required as written.
I put both anonymous functions just before the end </body> tag
and removed the internal "onload()" commands and left the code they controlled alone.
I'll post the demo code if anyone is interested as to what I did.