building account ajax functionality and maintain