create js for login page