does the same script tag moved to a different place work? If not, the bug is most likely in your script.
does the same script tag moved to a different place work? If not, the bug is most likely in your script.