slightly modify colour styling to be clearer for multi-record html output
add missing header
free memory on parse error