reindented HTML and better error UI for upload failures