move document.write to bottom on index