Better error handling and html output.