Altered to change the HTML file only if there is a change (in length!)