added basic functions to generate comments with jquery templates