reformat and html5ify