You cannot place javascript in the body because CSP rules don't allow it. Please place them in a Javascript file (see the media/js folder).