Write HTML preview to temp directory instead of running a server