Optimize html code