Update index.html

put script into success block