Move saving html files to its own function