Generating PDF files from HTML content

Although nowadays we have Email, SMS services integrated in most of web applications, sometimes there could be need of documentation for future reference which users may want to reuse later based on their need. Similar requirement we had in one of our web application where we wanted to provide option to user to generate single or bulk PDF files out of any HTML templates they have in their account. There was different features around the generation of PDF document but major work was involved in generation of PDF out of HTML which is also not difficult task when we have