I've modified the explode code to work better with longer records. For anybody who wants to use the explode code as a basis for a converter to other formats (e.g., epub), this should be handy. (In fact, an epub converter would be really easy. Just make sure the html is valid xhtml, and add the other stuff the epub format needs.)
The explode code probably isn't perfect, but it is probably better than it was.