Fixes to click handler and document.ready function call from Larry's code review