printing log on front-end