writes to html file