Can't get snippet to run on page load

Thanks Rob! Learning JS by sheer force is challenging sometimes.