put everthing in functions,it should work now