Php class to generate html code