Merging Global.asax.cs's LogError logic with ExceptionLog.LogException, including writing to file if unable to write to db.