generate the HTML document