Improve Html generator, added Lookup variables and Templates