added ajax and stuff