Handle HTML fragments as HTML in files