refactored html_client code to use seperate files for each template