Issue #16: Make sure we don't replace the inline html content with empty data.  Also, minor random bugfixes.