halfway with jquery implentation