issue37: redoing how functions are called on page load