move inline js out