inline javascript with template 2