preliminary work on HTML output, fixed a couple of bugs
documentation checkpoint
fixed a couple of tests