Fix the position of JavaScript in the document