Fix HTML writer, now some kind of failsafe mode
apply changes