add javascript to inputs