added ajax for front end and bakcend.
Maybe need support for backbutton