texinfo-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

branch master updated: * tp/Texinfo/Convert/HTML.pm (_convert_heading_co


From: Patrice Dumas
Subject: branch master updated: * tp/Texinfo/Convert/HTML.pm (_convert_heading_command): add a div for sections without nodes. (_default_format_element_footer, _default_format_end_file): call close_registered_sections_level() in _default_format_element_footer() and not in _default_format_end_file(). * tp/t/init/t2h_singular.init (singular_format_footer): call close_registered_sections_level().
Date: Fri, 19 Feb 2021 19:05:57 -0500

This is an automated email from the git hooks/post-receive script.

pertusus pushed a commit to branch master
in repository texinfo.

The following commit(s) were added to refs/heads/master by this push:
     new 2a668e0  * tp/Texinfo/Convert/HTML.pm (_convert_heading_command): add 
a div for sections without nodes. (_default_format_element_footer, 
_default_format_end_file): call close_registered_sections_level() in 
_default_format_element_footer() and not in _default_format_end_file(). * 
tp/t/init/t2h_singular.init (singular_format_footer): call 
close_registered_sections_level().
2a668e0 is described below

commit 2a668e044682437fb89ee8b21fac1737ddead450
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Sat Feb 20 01:05:45 2021 +0100

    * tp/Texinfo/Convert/HTML.pm (_convert_heading_command):
    add a div for sections without nodes.
    (_default_format_element_footer, _default_format_end_file):
    call close_registered_sections_level() in
    _default_format_element_footer() and not in
    _default_format_end_file().
    * tp/t/init/t2h_singular.init (singular_format_footer):
    call close_registered_sections_level().
---
 ChangeLog                                          | 11 +++
 tp/Texinfo/Convert/HTML.pm                         | 25 +++++--
 tp/t/init/t2h_singular.init                        |  1 +
 .../converters_tests/at_commands_in_refs.pl        |  2 +-
 .../at_commands_in_refs_latin1/res_html/index.html |  2 +-
 .../at_commands_in_refs_utf8/res_html/index.html   |  2 +-
 .../char_latin1_latin1_in_refs/res_html/index.html |  2 +-
 .../char_latin1_utf8_in_refs/res_html/index.html   |  2 +-
 .../char_latin2_latin2_in_refs/res_html/index.html |  2 +-
 .../japanese_shift_jis/res_html/index.html         |  2 +-
 tp/t/results/converters_tests/ref_in_sectioning.pl | 50 +++++++++----
 .../sample_utf8/res_html/index.html                |  2 +-
 .../some_at_commands_in_ref_nodes.pl               |  4 +-
 tp/t/results/coverage_braces/footnote_no_node.pl   |  6 +-
 .../coverage_braces/two_footnotes_in_nodes.pl      |  6 +-
 .../two_footnotes_in_nodes_separate.pl             |  4 +-
 tp/t/results/float/complex_float.pl                |  4 +-
 tp/t/results/float/float_copying.pl                |  4 +-
 .../float/numbering_captions_listoffloats.pl       |  2 +-
 .../float_copying/res_html/Copying-and-floats.html |  2 +-
 .../formatting/float_copying/res_html/index.html   |  2 +-
 tp/t/results/formatting/texi_bib_example.pl        |  2 +-
 tp/t/results/formatting/texi_glossary.pl           |  2 +-
 .../character_number_leading_toc_stoc.pl           | 18 +++--
 tp/t/results/html_tests/check_htmlxref.pl          |  2 +-
 tp/t/results/html_tests/documentdescription.pl     |  6 +-
 .../results/html_tests/index_and_node_same_name.pl |  6 +-
 tp/t/results/html_tests/index_below.pl             | 12 +++-
 .../res_html/circumflex.html                       |  2 +-
 .../redirection_same_labels/res_html/index.html    |  2 +-
 .../redirection_same_labels/res_html/umlaut.html   |  2 +-
 tp/t/results/html_tests/shortcontents_no_top.pl    | 14 ++--
 .../html_tests/test_xrefautomaticsectiontitle.pl   |  4 +-
 .../text_before_top_and_contents_after_title.pl    |  4 +-
 .../htmlxref/htmlxref_nodes/res_html/index.html    |  2 +-
 .../htmlxref_nodes/res_html/other-nodes.html       |  2 +-
 .../htmlxref_only_mono_nodes/res_html/index.html   |  2 +-
 .../res_html/other-nodes.html                      |  2 +-
 .../htmlxref_only_split_nodes/res_html/index.html  |  2 +-
 .../res_html/other-nodes.html                      |  2 +-
 .../indices/printindex_index_entry_in_copying.pl   |  2 +
 ...rintindex_index_entry_in_copying_in_footnote.pl |  2 +
 ...ndex_index_entry_in_copying_no_insertcopying.pl |  2 +
 tp/t/results/languages/appendix_translated.pl      |  4 +-
 .../res_html/multiple_lang_chapters.html           |  4 +-
 .../navigation_chapter/res_html/chapter.html       |  6 +-
 .../layout/navigation_chapter/res_html/index.html  |  2 +-
 .../res_html/chapter.html                          |  6 +-
 .../res_html/index.html                            |  2 +-
 .../res_html/chapter.html                          |  6 +-
 .../res_html/index.html                            |  2 +-
 .../res_html/chapter.html                          |  6 +-
 .../res_html/index.html                            |  2 +-
 .../layout/navigation_node/res_html/chapter.html   |  2 +-
 .../layout/navigation_node/res_html/index.html     |  2 +-
 .../layout/navigation_node/res_html/section.html   |  2 +-
 .../navigation_node/res_html/subsection.html       |  2 +-
 .../navigation_node_no_header/res_html/index.html  |  2 +-
 .../res_html/index.html                            |  2 +-
 .../navigation_node_vertical/res_html/chapter.html |  2 +-
 .../navigation_node_vertical/res_html/index.html   |  2 +-
 .../navigation_node_vertical/res_html/section.html |  2 +-
 .../res_html/subsection.html                       |  2 +-
 .../navigation_section/res_html/chapter.html       |  2 +-
 .../layout/navigation_section/res_html/index.html  |  2 +-
 .../navigation_section/res_html/section.html       |  4 +-
 .../res_html/chapter.html                          |  2 +-
 .../res_html/index.html                            |  2 +-
 .../res_html/section.html                          |  4 +-
 .../res_html/chapter.html                          |  2 +-
 .../res_html/index.html                            |  2 +-
 .../res_html/section.html                          |  4 +-
 .../res_html/chapter.html                          |  2 +-
 .../res_html/index.html                            |  2 +-
 .../res_html/section.html                          |  4 +-
 .../no_monolithic/res_html/no_monolithic.html      |  2 +-
 tp/t/results/menu/comment_on_menu_line.pl          |  2 +-
 tp/t/results/menu/detailmenu_on_subnodes.pl        |  2 +-
 .../no_empty_line_between_headings.pl              | 14 ++--
 tp/t/results/morecoverage/formatting_fr.pl         |  2 +-
 tp/t/results/morecoverage/texi_formatting.pl       |  4 +-
 .../index_no_node/res_html/Chapter-2.html          |  4 +-
 .../index_no_node/res_html/Chapter.html            |  4 +-
 .../moreindices/index_no_node/res_html/index.html  |  8 ++-
 .../index_no_node/res_html/unnumbered.html         |  4 +-
 .../moreindices/index_split/res_html/first.html    |  4 +-
 .../moreindices/index_split/res_html/index.html    |  2 +-
 .../index_split/res_html/second-chapter.html       |  2 +-
 .../index_split_nodes/res_html/first.html          |  2 +-
 .../index_split_nodes/res_html/index.html          |  2 +-
 .../index_split_nodes/res_html/second-chapter.html |  2 +-
 .../index_split_nodes/res_html/section-1.html      |  2 +-
 .../index_split_nodes/res_html/section-2.html      |  2 +-
 .../index_split_nodes/res_html/section-3.html      |  2 +-
 .../index_split_nodes/res_html/subsection-1.html   |  2 +-
 .../index_split_nodes/res_html/subsection-2.html   |  2 +-
 .../split_chapter_index/res_html/first.html        |  6 +-
 .../split_chapter_index/res_html/index.html        |  2 +-
 .../res_html/more_sections_than_nodes.html         | 36 +++++++---
 .../node_footnote_use_node/res_html/chapter.html   |  2 +-
 .../res_html/third-node.html                       |  2 +-
 .../res_html/index.html                            |  2 +-
 .../res_html/placed_things_before_element.html     |  6 +-
 .../sectioning_frames/res_html/First-node.html     |  4 +-
 .../sectioning_frames/res_html/Second-node.html    |  2 +-
 .../res_html/Third-node-unnumbered.html            |  2 +-
 .../sectioning_frames/res_html/index.html          |  2 +-
 tp/t/results/regions/anchor_in_titlepage.pl        |  6 +-
 .../regions/anchor_in_titlepage_titlepage.pl       |  6 +-
 tp/t/results/regions/ref_in_copying.pl             |  2 +-
 tp/t/results/sectioning/anchor_in_footnote.pl      |  6 +-
 .../sectioning/anchor_in_footnote_separate.pl      |  4 +-
 .../sectioning/chapter_before_and_after_part.pl    | 14 ++--
 tp/t/results/sectioning/chapter_before_part.pl     | 10 ++-
 tp/t/results/sectioning/chapter_between_nodes.pl   |  6 +-
 .../chapter_node_before_and_after_part.pl          |  8 ++-
 .../sectioning/character_and_spaces_in_refs.pl     |  2 +-
 .../res_html/index.html                            |  2 +-
 tp/t/results/sectioning/contents.pl                | 46 ++++++++----
 .../sectioning/contents_and_shortcontents.pl       | 46 ++++++++----
 tp/t/results/sectioning/contents_in_html_text.pl   | 18 +++--
 tp/t/results/sectioning/double_part.pl             | 10 ++-
 tp/t/results/sectioning/empty_top_node_up.pl       |  2 +-
 tp/t/results/sectioning/external_node_in_menu.pl   |  2 +-
 tp/t/results/sectioning/internal_top_node_up.pl    |  2 +-
 tp/t/results/sectioning/next_in_menu_is_below.pl   |  2 +-
 .../results/sectioning/no_argument_and_contents.pl |  8 ++-
 tp/t/results/sectioning/no_menu.pl                 |  2 +-
 .../sectioning/node_part_chapter_after_chapter.pl  |  8 ++-
 .../sectioning/node_part_chapter_after_top.pl      |  8 ++-
 .../nodes_after_top_before_chapter_nodes.pl        |  2 +-
 .../nodes_after_top_before_chapter_not_split.pl    |  2 +-
 ...ore_chapter_not_split_no_use_node_directions.pl |  2 +-
 .../nodes_after_top_before_chapter_sections.pl     |  2 +-
 .../nodes_after_top_before_section_nodes.pl        |  2 +-
 .../nodes_after_top_before_section_sections.pl     |  2 +-
 .../non_automatic_internal_top_node_up.pl          |  2 +-
 .../non_automatic_top_node_up_and_url.pl           |  2 +-
 .../sectioning/non_automatic_top_node_up_url.pl    |  2 +-
 tp/t/results/sectioning/one_subsection.pl          |  6 +-
 tp/t/results/sectioning/part_before_chapter.pl     | 10 ++-
 tp/t/results/sectioning/part_before_section.pl     | 10 ++-
 tp/t/results/sectioning/part_before_top.pl         | 10 ++-
 tp/t/results/sectioning/part_chapter_after_top.pl  |  6 +-
 tp/t/results/sectioning/part_node_after_top.pl     |  6 +-
 tp/t/results/sectioning/part_node_before_top.pl    |  6 +-
 .../sectioning/part_node_chapter_after_top.pl      |  6 +-
 .../sectioning/part_node_chapter_appendix.pl       | 10 ++-
 .../sectioning/part_node_chapter_node_appendix.pl  |  6 +-
 .../sectioning/part_node_node_part_appendix.pl     | 12 ++--
 tp/t/results/sectioning/part_node_part_appendix.pl | 14 ++--
 .../sectioning/part_node_part_node_appendix.pl     | 12 ++--
 .../sectioning/placed_things_before_element.pl     |  6 +-
 .../sectioning/protected_node_parentheses.pl       |  4 +-
 tp/t/results/sectioning/section_before_part.pl     | 10 ++-
 tp/t/results/sectioning/section_before_top.pl      |  2 +-
 .../results/sectioning/section_below_unnumbered.pl |  2 +-
 .../sectioning/section_below_unnumbered_no_top.pl  | 10 ++-
 .../sectioning/section_chapter_before_top_nodes.pl |  2 +-
 .../sectioning/section_in_unnumbered_info.pl       |  2 +-
 .../sectioning/section_in_unnumbered_plaintext.pl  |  2 +-
 .../results/sectioning/section_node_before_part.pl |  4 +-
 tp/t/results/sectioning/sections_test.pl           | 48 +++++++++----
 .../sectioning/sections_test_no_use_nodes.pl       | 44 +++++++++---
 ...ctions_test_no_use_nodes_use_node_directions.pl | 44 +++++++++---
 tp/t/results/sectioning/shortcontents.pl           | 46 ++++++++----
 .../sectioning/top_no_argument_and_content.pl      |  6 +-
 tp/t/results/sectioning/top_node_part_top.pl       |  4 +-
 tp/t/results/sectioning/top_node_up_url.pl         |  2 +-
 tp/t/results/sectioning/top_without_node_nodes.pl  |  4 +-
 .../sectioning/top_without_node_sections.pl        |  4 +-
 tp/t/results/sectioning/two_nodes_at_the_end.pl    |  2 +-
 .../sectioning/two_nodes_between_chapters.pl       |  2 +-
 .../sectioning/unnumbered_before_node_top_top.pl   |  4 +-
 .../sectioning/unnumbered_before_top_node.pl       |  6 +-
 .../unnumbered_top_without_node_nodes.pl           |  8 ++-
 .../unnumbered_top_without_node_sections.pl        |  8 ++-
 .../contents_and_parts/contents_and_parts.html     | 10 ++-
 .../chapter.html                                   |  4 +-
 .../index.html                                     |  2 +-
 .../index.html                                     |  2 +-
 .../double_contents_chapter/chapter.html           |  4 +-
 .../res_parser/double_contents_chapter/index.html  |  2 +-
 .../double_contents_inline_chapter/chapter.html    |  4 +-
 .../double_contents_inline_chapter/index.html      |  2 +-
 .../double_contents_inline_nodes/chapter.html      |  2 +-
 .../double_contents_inline_nodes/index.html        |  2 +-
 .../double_contents_inline_nodes/section.html      |  2 +-
 .../double_contents_inline_section/chapter.html    |  2 +-
 .../double_contents_inline_section/index.html      |  2 +-
 .../double_contents_inline_section/section.html    |  2 +-
 .../res_parser/double_contents_nodes/chapter.html  |  2 +-
 .../res_parser/double_contents_nodes/index.html    |  2 +-
 .../res_parser/double_contents_nodes/section.html  |  2 +-
 .../double_contents_section/chapter.html           |  2 +-
 .../res_parser/double_contents_section/index.html  |  2 +-
 .../double_contents_section/section.html           |  2 +-
 .../index_no_node_no_top/index_no_node_no_top.html | 20 ++++--
 .../res_parser/index_special_region/Chapter.html   |  4 +-
 .../index_special_region/Copying-and-indices.html  |  2 +-
 .../res_parser/index_special_region/index.html     |  2 +-
 .../index_special_region_html/Chapter.html         |  4 +-
 .../Copying-and-indices.html                       |  2 +-
 .../index_special_region_html/index.html           |  2 +-
 .../Chapter.html                                   |  4 +-
 .../Copying-and-indices.html                       |  2 +-
 .../index.html                                     |  2 +-
 .../Chapter.html                                   |  4 +-
 .../Copying-and-indices.html                       |  2 +-
 .../index.html                                     |  2 +-
 .../index_special_region_no_region/Chapter.html    |  4 +-
 .../Copying-and-indices.html                       |  2 +-
 .../index_special_region_no_region/index.html      |  2 +-
 .../Chapter.html                                   |  4 +-
 .../Copying-and-indices.html                       |  2 +-
 .../index_special_region_no_region_html/index.html |  2 +-
 tp/tests/indices/res_parser/index_table/index.html |  2 +-
 .../res_parser/index_table/indices-refs.html       |  4 +-
 .../index_table/node-with-ftable-and-vtable.html   |  2 +-
 .../index_table/node-with-printindex.html          |  2 +-
 .../chapter.html                                   |  2 +-
 .../index.html                                     |  2 +-
 .../chapter.html                                   |  2 +-
 .../index.html                                     |  2 +-
 .../printindex_between_part_chapter.html           |  4 +-
 .../Copying-and-indices.html                       |  2 +-
 .../index_special_region_html/index.html           |  6 +-
 .../Copying-and-indices.html                       |  2 +-
 .../index.html                                     |  6 +-
 .../Copying-and-indices.html                       |  2 +-
 .../index_special_region_no_region_html/index.html |  6 +-
 .../chapter.html                                   |  2 +-
 .../index.html                                     |  2 +-
 .../chapter.html                                   |  2 +-
 .../index.html                                     |  2 +-
 .../layout/res_parser/formatting_chm/chapter.html  |  1 +
 .../layout/res_parser/formatting_chm/chapter2.html |  5 +-
 .../res_parser/formatting_chm/formatting.html      |  1 +
 .../res_parser/formatting_chm/formatting_toc.html  |  2 -
 .../formatting_chm/s_002d_002dect_002cion.html     |  1 +
 .../res_parser/formatting_chm/subsection.html      |  1 +
 ...tion-_0060_0060simple_002ddouble_002d_002d.html |  1 +
 ...02d_002dfour_002d_002d_002d_002d_0027_0027.html |  2 +-
 .../res_parser/formatting_exotic/chapter.html      |  2 +-
 .../res_parser/formatting_exotic/chapter2.html     |  2 +-
 .../layout/res_parser/formatting_exotic/index.html |  2 +-
 .../formatting_exotic/s_002d_002dect_002cion.html  |  6 +-
 .../res_parser/formatting_html_nodes/chapter.html  |  2 +-
 .../res_parser/formatting_html_nodes/chapter2.html |  2 +-
 .../res_parser/formatting_html_nodes/index.html    |  2 +-
 .../s_002d_002dect_002cion.html                    |  2 +-
 .../formatting_html_nodes/subsection.html          |  2 +-
 ...tion-_0060_0060simple_002ddouble_002d_002d.html |  2 +-
 ...02d_002dfour_002d_002d_002d_002d_0027_0027.html |  2 +-
 .../res_parser/formatting_nodes/chapter.html       |  2 +-
 .../res_parser/formatting_nodes/chapter2.html      |  2 +-
 .../layout/res_parser/formatting_nodes/index.html  |  2 +-
 .../formatting_nodes/s_002d_002dect_002cion.html   |  2 +-
 .../res_parser/formatting_nodes/subsection.html    |  2 +-
 ...tion-_0060_0060simple_002ddouble_002d_002d.html |  2 +-
 ...02d_002dfour_002d_002d_002d_002d_0027_0027.html |  2 +-
 .../chapter.html                                   |  2 +-
 .../subsection.html                                |  2 +-
 tp/tests/many_input_files/tex_l2h_res/tex.html     |  8 +--
 .../many_input_files/tex_l2h_res/tex_complex.html  |  8 +--
 tp/tests/many_input_files/tex_t4ht_res/tex.html    |  8 +--
 .../many_input_files/tex_t4ht_res/tex_complex.html |  8 +--
 .../res_parser/block_EOL_tex/block_EOL.html        | 23 +++---
 .../res_parser/formatting_singular/chapter.html    |  9 ++-
 .../res_parser/formatting_singular/chapter2.html   | 12 ++--
 .../res_parser/formatting_singular/index.htm       | 82 +++++++++-------------
 .../s_002d_002dect_002cion.html                    |  8 ++-
 .../res_parser/formatting_singular/sing_abt.htm    |  2 +
 .../res_parser/formatting_singular/sing_fot.htm    |  4 +-
 .../res_parser/formatting_singular/sing_ovr.htm    |  2 +
 .../res_parser/formatting_singular/sing_toc.htm    |  2 +
 .../res_parser/formatting_singular/subsection.html |  8 ++-
 ...tion-_0060_0060simple_002ddouble_002d_002d.html |  8 ++-
 ...02d_002dfour_002d_002d_002d_002d_0027_0027.html |  9 +--
 .../math_not_closed/math_not_closed.html           |  8 +--
 .../res_parser/simplest_httex/simplest.html        |  8 +--
 tp/tests/tex_html/res_parser/tex/tex.html          |  8 +--
 .../res_parser/tex_accents_httex/tex_accents.html  |  2 +
 .../res_parser/tex_accents_l2h/tex_accents.html    |  2 +
 .../res_parser/tex_complex_httex/tex_complex.html  |  8 +--
 .../res_parser/tex_complex_l2h/tex_complex.html    |  8 +--
 .../res_parser/tex_eqalign_httex/tex_eqalign.html  |  8 +--
 .../res_parser/tex_eqalign_l2h/tex_eqalign.html    |  8 +--
 .../res_parser/tex_gdef_httex/tex_gdef.html        |  8 +--
 .../tex_html/res_parser/tex_gdef_l2h/tex_gdef.html |  8 +--
 tp/tests/tex_html/res_parser/tex_httex/tex.html    |  8 +--
 .../res_parser/tex_in_copying/tex_in_copying.html  | 12 ++--
 .../res_parser/tex_not_closed/tex_not_closed.html  |  8 +--
 tp/tests/tex_html/res_parser/tex_notex/tex.html    |  8 +--
 294 files changed, 1020 insertions(+), 614 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 1874568..894bfab 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2021-02-20  Patrice Dumas  <pertusus@free.fr>
+
+       * tp/Texinfo/Convert/HTML.pm (_convert_heading_command):
+       add a div for sections without nodes.
+       (_default_format_element_footer, _default_format_end_file):
+       call close_registered_sections_level() in
+       _default_format_element_footer() and not in
+       _default_format_end_file().
+       * tp/t/init/t2h_singular.init (singular_format_footer):
+       call close_registered_sections_level().
+
 2021-02-18  Gavin Smith  <gavinsmith0123@gmail.com>
 
        Fix compiler warnings.
diff --git a/tp/Texinfo/Convert/HTML.pm b/tp/Texinfo/Convert/HTML.pm
index faf2e52..fa6a442 100644
--- a/tp/Texinfo/Convert/HTML.pm
+++ b/tp/Texinfo/Convert/HTML.pm
@@ -2428,6 +2428,9 @@ sub close_registered_sections_level($$)
 {
   my $self = shift;
   my $level = shift;
+  if (not defined($level)) {
+    cluck 'close_registered_sections_level $level not defined';
+  }
   my @closed_elements;
   my $result = '';
   while (@{$self->{'pending_closes'}} > $level) {
@@ -2456,8 +2459,17 @@ sub _convert_heading_command($$$$$)
   }
 
   my $element_id = $self->command_id($command);
-  my $section = $command->{'extra'}->{'associated_section'};
-  if ($cmdname eq 'node' and $section) {
+  my $section;
+  if ($cmdname eq 'node' and $command->{'extra'}->{'associated_section'}) {
+    $section = $command->{'extra'}->{'associated_section'};
+  } elsif ($cmdname ne 'node'
+           and not $command->{'extra'}->{'associated_node'}
+           # to avoid *heading* @-commands
+           and $Texinfo::Common::root_commands{$cmdname}) {
+    $section = $command;
+  }
+
+  if ($section) {
     my $level = $section->{'level'};
     $result .= join('', $self->close_registered_sections_level($level));
     $self->register_opened_section_level($level, "</div>\n");
@@ -2504,6 +2516,9 @@ sub _convert_heading_command($$$$$)
   } elsif (defined $command->{'level'}) {
     $heading_level = $command->{'level'};
   } else {
+    # for *heading* @-commands which do not have a level
+    # in the document as they are not associated with the
+    # sectioning tree, but still have a $heading_level
     $heading_level = Texinfo::Structuring::section_level($command);
   }
 
@@ -4794,6 +4809,9 @@ sub _default_format_element_footer($$$$)
 </tr>
 </table>"."\n";
   }
+  if ($end_page) {
+    $result .= join('', $self->close_registered_sections_level(0));
+  }
 
   my $rule = '';
   my $buttons;
@@ -6549,7 +6567,6 @@ sub _default_format_program_string($)
 sub _default_format_end_file($)
 {
   my $self = shift;
-  my $closing_sections_text = join('', 
$self->close_registered_sections_level(0));
   my $program_text = '';
   if ($self->get_conf('PROGRAM_NAME_IN_FOOTER')) {
     my $program_string = &{$self->{'format_program_string'}}($self);
@@ -6571,7 +6588,7 @@ sub _default_format_end_file($)
 .'</small></a>';
   }
 
-  return "${closing_sections_text}${program_text}
+  return "${program_text}
 
 $pre_body_close
 </body>
diff --git a/tp/t/init/t2h_singular.init b/tp/t/init/t2h_singular.init
index c772bb5..f13c3d4 100644
--- a/tp/t/init/t2h_singular.init
+++ b/tp/t/init/t2h_singular.init
@@ -89,6 +89,7 @@ sub singular_format_footer($$$$)
     $result .= $self->get_conf('DEFAULT_RULE')."\n"
        if (defined($self->get_conf('DEFAULT_RULE')));
     if ($end_page) {
+      $result .= join('', $self->close_registered_sections_level(0));
       $result .= &{$self->{'format_navigation_header_panel'}}($self, 
                                             $buttons, undef, $element);
     }
diff --git a/tp/t/results/converters_tests/at_commands_in_refs.pl 
b/tp/t/results/converters_tests/at_commands_in_refs.pl
index 3bd179e..b759fed 100644
--- a/tp/t/results/converters_tests/at_commands_in_refs.pl
+++ b/tp/t/results/converters_tests/at_commands_in_refs.pl
@@ -23228,9 +23228,9 @@ Previous: <a href="#gH-3rd" accesskey="p" 
rel="prev"><sub>g</sub>H 3<sup>rd</sup
 </p>
 <p><a 
href="#http_003a_002f_002fsomewhere_005faaa-url-_002fman_002ecgi_002f1_002fls"><a
 href="http://somewhere_aaa";>http://somewhere_aaa</a> <a href="url">text</a> <a 
href="/man.cgi/1/ls">ls</a></a>
 </p>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git 
a/tp/t/results/converters_tests/at_commands_in_refs_latin1/res_html/index.html 
b/tp/t/results/converters_tests/at_commands_in_refs_latin1/res_html/index.html
index 1e4b818..a3b6c8b 100644
--- 
a/tp/t/results/converters_tests/at_commands_in_refs_latin1/res_html/index.html
+++ 
b/tp/t/results/converters_tests/at_commands_in_refs_latin1/res_html/index.html
@@ -76,12 +76,12 @@ Next: <a href="-_007b-_007d.html" accesskey="n" rel="next"> 
{ }</a> &nbsp; </p>
 <li><a href="gH-3rd.html"><sub>g</sub>H 3<sup>rd</sup></a></li>
 <li><a 
href="http_003a_002f_002fsomewhere_005faaa-url-_002fman_002ecgi_002f1_002fls.html"><a
 href="http://somewhere_aaa";>http://somewhere_aaa</a> <a href="url">text</a> <a 
href="/man.cgi/1/ls">ls</a></a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="-_007b-_007d.html" accesskey="n" rel="next"> { }</a> &nbsp; </p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/t/results/converters_tests/at_commands_in_refs_utf8/res_html/index.html 
b/tp/t/results/converters_tests/at_commands_in_refs_utf8/res_html/index.html
index 7f515b2..144120f 100644
--- a/tp/t/results/converters_tests/at_commands_in_refs_utf8/res_html/index.html
+++ b/tp/t/results/converters_tests/at_commands_in_refs_utf8/res_html/index.html
@@ -76,12 +76,12 @@ Next: <a href="-_007b-_007d.html" accesskey="n" rel="next"> 
{ }</a> &nbsp; </p>
 <li><a href="gH-3rd.html"><sub>g</sub>H 3<sup>rd</sup></a></li>
 <li><a 
href="http_003a_002f_002fsomewhere_005faaa-url-_002fman_002ecgi_002f1_002fls.html"><a
 href="http://somewhere_aaa";>http://somewhere_aaa</a> <a href="url">text</a> <a 
href="/man.cgi/1/ls">ls</a></a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="-_007b-_007d.html" accesskey="n" rel="next"> { }</a> &nbsp; </p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/t/results/converters_tests/char_latin1_latin1_in_refs/res_html/index.html 
b/tp/t/results/converters_tests/char_latin1_latin1_in_refs/res_html/index.html
index d38f33b..0d5f784 100644
--- 
a/tp/t/results/converters_tests/char_latin1_latin1_in_refs/res_html/index.html
+++ 
b/tp/t/results/converters_tests/char_latin1_latin1_in_refs/res_html/index.html
@@ -99,12 +99,12 @@ Next: <a href="a-e-i-o-u-y-A-E-I-O-U.html" accesskey="n" 
rel="next">
 <li><a href="a-e-i-o-u-A-E-I-O-U.html" accesskey="4">� � � � � � � � � 
�</a></li>
 <li><a href="c.html" accesskey="5">�</a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="a-e-i-o-u-y-A-E-I-O-U.html" accesskey="n" rel="next">� � � � � 
� � � � � �</a> &nbsp; [<a href="#Top" title="Index" rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/t/results/converters_tests/char_latin1_utf8_in_refs/res_html/index.html 
b/tp/t/results/converters_tests/char_latin1_utf8_in_refs/res_html/index.html
index 81d4892..419c8f8 100644
--- a/tp/t/results/converters_tests/char_latin1_utf8_in_refs/res_html/index.html
+++ b/tp/t/results/converters_tests/char_latin1_utf8_in_refs/res_html/index.html
@@ -99,12 +99,12 @@ Next: <a href="a-e-i-o-u-y-A-E-I-O-U.html" accesskey="n" 
rel="next">ä ë ï ö
 <li><a href="a-e-i-o-u-A-E-I-O-U.html" accesskey="4">â ê î ô û Â Ê Î Ô 
Û</a></li>
 <li><a href="c.html" accesskey="5">ç</a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="a-e-i-o-u-y-A-E-I-O-U.html" accesskey="n" rel="next">ä ë ï ö ü 
ÿ Ä Ë Ï Ö Ü</a> &nbsp; [<a href="#Top" title="Index" rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/t/results/converters_tests/char_latin2_latin2_in_refs/res_html/index.html 
b/tp/t/results/converters_tests/char_latin2_latin2_in_refs/res_html/index.html
index 4f7e406..a1095ba 100644
--- 
a/tp/t/results/converters_tests/char_latin2_latin2_in_refs/res_html/index.html
+++ 
b/tp/t/results/converters_tests/char_latin2_latin2_in_refs/res_html/index.html
@@ -68,12 +68,12 @@ Next: <a href="A-a-_002c-E-e.html" accesskey="n" rel="next">
 <ul class="section-toc">
 <li><a href="A-a-_002c-E-e.html" accesskey="1">� � � � �</a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="A-a-_002c-E-e.html" accesskey="n" rel="next">� � � � �</a> 
&nbsp; [<a href="#Top" title="Index" rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/t/results/converters_tests/japanese_shift_jis/res_html/index.html 
b/tp/t/results/converters_tests/japanese_shift_jis/res_html/index.html
index 7bb9b86..427185e 100644
--- a/tp/t/results/converters_tests/japanese_shift_jis/res_html/index.html
+++ b/tp/t/results/converters_tests/japanese_shift_jis/res_html/index.html
@@ -65,12 +65,12 @@ Next: <a href="Preface.html" accesskey="n" 
rel="next">Preface</a> &nbsp; </p>
 <li><a href="Preface.html" accesskey="1">Preface</a></li>
 <li><a href="Introduction.html" accesskey="2">Introduction</a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="Preface.html" accesskey="n" rel="next">Preface</a> &nbsp; </p>
 </div>
-</div>
 
 
 
diff --git a/tp/t/results/converters_tests/ref_in_sectioning.pl 
b/tp/t/results/converters_tests/ref_in_sectioning.pl
index dc0100f..d5c82e0 100644
--- a/tp/t/results/converters_tests/ref_in_sectioning.pl
+++ b/tp/t/results/converters_tests/ref_in_sectioning.pl
@@ -2605,30 +2605,56 @@ $result_converted{'html_text'}->{'ref_in_sectioning'} = 
'
 <li><a href="#Top_002c-xref-Top-filename-only_002c-no-spaces">See <a 
data-manual="filename" href="filename.html#Top">(filename)Top</a>, xref Top 
filename only, no spaces</a></li>
 <li><a href="#filename_002e-xref-filename-only_002c-no-spaces">See <a 
data-manual="filename" href="filename.html#Top">(filename)</a>. xref filename 
only, no spaces</a></li>
 </ul>
-<span id="node-node_002c-crossref-arg2"></span><h3 class="section">2.1 <a 
href="#node">cross ref name</a>  node, crossref arg2</h3>
+<div class="section" id="node-node_002c-crossref-arg2">
+<h3 class="section">2.1 <a href="#node">cross ref name</a>  node, crossref 
arg2</h3>
 
-<span id="node-code-node_002c-samptitle-arg3"></span><h3 class="section">2.2 
<a href="#node">&lsquo;<samp>title</samp>&rsquo;</a>  code node, samptitle 
arg3</h3>
+</div>
+<div class="section" id="node-code-node_002c-samptitle-arg3">
+<h3 class="section">2.2 <a href="#node">&lsquo;<samp>title</samp>&rsquo;</a>  
code node, samptitle arg3</h3>
 
-<span id="node-code-node_002c-file-name"></span><h3 class="section">2.3 <a 
data-manual="file name" href="file name.html#node">(file 
name)<code>node</code></a> code node, file name</h3>
+</div>
+<div class="section" id="node-code-node_002c-file-name">
+<h3 class="section">2.3 <a data-manual="file name" href="file 
name.html#node">(file name)<code>node</code></a> code node, file name</h3>
 
-<span id="node-node-and-manual"></span><h3 class="section">2.4 
&lsquo;node&rsquo; in <cite>Manual</cite> node and manual</h3>
+</div>
+<div class="section" id="node-node-and-manual">
+<h3 class="section">2.4 &lsquo;node&rsquo; in <cite>Manual</cite> node and 
manual</h3>
 
-<span id="Top-Top-and-manual"></span><h3 class="section">2.5 
<cite>Manual</cite> Top and manual</h3>
+</div>
+<div class="section" id="Top-Top-and-manual">
+<h3 class="section">2.5 <cite>Manual</cite> Top and manual</h3>
 
-<span id="Manual-no-node-just-manual"></span><h3 class="section">2.6 
<cite>Manual</cite> no node just manual</h3>
+</div>
+<div class="section" id="Manual-no-node-just-manual">
+<h3 class="section">2.6 <cite>Manual</cite> no node just manual</h3>
 
-<span id="file-name-no-node-just-file-name"></span><h3 class="section">2.7 <a 
data-manual="file name" href="file name.html#Top">(file name)</a> no node just 
file name</h3>
+</div>
+<div class="section" id="file-name-no-node-just-file-name">
+<h3 class="section">2.7 <a data-manual="file name" href="file 
name.html#Top">(file name)</a> no node just file name</h3>
 
-<span id="a-inforef-a-b-c"></span><h3 class="section">2.8 See <a 
data-manual="c" href="c.html#a">(c)b</a> inforef a b c</h3>
+</div>
+<div class="section" id="a-inforef-a-b-c">
+<h3 class="section">2.8 See <a data-manual="c" href="c.html#a">(c)b</a> 
inforef a b c</h3>
 
-<span id="g_t_0028Top_0029-pxref-Top-file-name_002c-spaces"></span><h3 
class="section">2.9 (see <a data-manual="file name" href="file 
name.html#Top">(file name)Top</a>) pxref Top file name, spaces</h3>
+</div>
+<div class="section" id="g_t_0028Top_0029-pxref-Top-file-name_002c-spaces">
+<h3 class="section">2.9 (see <a data-manual="file name" href="file 
name.html#Top">(file name)Top</a>) pxref Top file name, spaces</h3>
 
-<span id="g_t_0028file-name_0029-pxref-file-name-only_002c-spaces"></span><h3 
class="section">2.10 (see <a data-manual="file name" href="file 
name.html#Top">(file name)</a>) pxref file name only, spaces</h3>
+</div>
+<div class="section" 
id="g_t_0028file-name_0029-pxref-file-name-only_002c-spaces">
+<h3 class="section">2.10 (see <a data-manual="file name" href="file 
name.html#Top">(file name)</a>) pxref file name only, spaces</h3>
 
-<span id="Top_002c-xref-Top-filename-only_002c-no-spaces"></span><h3 
class="section">2.11 See <a data-manual="filename" 
href="filename.html#Top">(filename)Top</a>, xref Top filename only, no 
spaces</h3>
+</div>
+<div class="section" id="Top_002c-xref-Top-filename-only_002c-no-spaces">
+<h3 class="section">2.11 See <a data-manual="filename" 
href="filename.html#Top">(filename)Top</a>, xref Top filename only, no 
spaces</h3>
 
-<span id="filename_002e-xref-filename-only_002c-no-spaces"></span><h3 
class="section">2.12 See <a data-manual="filename" 
href="filename.html#Top">(filename)</a>. xref filename only, no spaces</h3>
+</div>
+<div class="section" id="filename_002e-xref-filename-only_002c-no-spaces">
+<h3 class="section">2.12 See <a data-manual="filename" 
href="filename.html#Top">(filename)</a>. xref filename only, no spaces</h3>
 
+</div>
+</div>
+</div>
 <hr>
 ';
 
diff --git a/tp/t/results/converters_tests/sample_utf8/res_html/index.html 
b/tp/t/results/converters_tests/sample_utf8/res_html/index.html
index 5fffbb8..2692e28 100644
--- a/tp/t/results/converters_tests/sample_utf8/res_html/index.html
+++ b/tp/t/results/converters_tests/sample_utf8/res_html/index.html
@@ -75,12 +75,12 @@ Texinfo中文示例
 </ul>
 </div>
 </div>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="DiYiZhang_0028First-Chapter_0029.html" accesskey="n" 
rel="next">第一章(First Chapter)</a> &nbsp; [<a href="#SEC_Contents" title="Table 
of contents" rel="contents">Contents</a>][<a href="Index-node.html" 
title="Index" rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git a/tp/t/results/converters_tests/some_at_commands_in_ref_nodes.pl 
b/tp/t/results/converters_tests/some_at_commands_in_ref_nodes.pl
index bb24866..e7c4d0a 100644
--- a/tp/t/results/converters_tests/some_at_commands_in_ref_nodes.pl
+++ b/tp/t/results/converters_tests/some_at_commands_in_ref_nodes.pl
@@ -1847,7 +1847,9 @@ 
$result_converted{'html_text'}->{'some_at_commands_in_ref_nodes'} = '
 <span id="A-SC-node-i-i-E-l-C-_00a1"></span><h2 class="chapter">1 A 
<small>SC</small> node &iuml; &iuml; &#274;` &#322; &#262;, &iexcl;</h2>
 
 <p>see <a data-manual="manual" 
href="manual.html#a-strong-ref-with-SC_002c-a-i-trema-_00ef_002c-a-dotless-i-trema-_00ef-_1e14-and-exclamdown-_00a1">(manual)a
 <strong>strong</strong> ref with <small>SC</small>, a i trema &iuml;, a 
dotless i trema &iuml; &#274;` and exclamdown &iexcl;</a>.
-</p><hr>
+</p></div>
+</div>
+<hr>
 ';
 
 
diff --git a/tp/t/results/coverage_braces/footnote_no_node.pl 
b/tp/t/results/coverage_braces/footnote_no_node.pl
index 025d8cf..b91a346 100644
--- a/tp/t/results/coverage_braces/footnote_no_node.pl
+++ b/tp/t/results/coverage_braces/footnote_no_node.pl
@@ -154,7 +154,8 @@ F(1).
 ';
 
 
-$result_converted{'html_text'}->{'footnote_no_node'} = '<span 
id="top"></span><h1 class="top">top</h1>
+$result_converted{'html_text'}->{'footnote_no_node'} = '<div class="top" 
id="top">
+<h1 class="top">top</h1>
 
 <p>F<a id="DOCF1" href="#FOOT1"><sup>1</sup></a>.
 </p><div class="footnote">
@@ -164,6 +165,7 @@ $result_converted{'html_text'}->{'footnote_no_node'} = 
'<span id="top"></span><h
 <h5><a id="FOOT1" href="#DOCF1">(1)</a></h5>
 <p>In footnote</p>
 </div>
-<hr>';
+<hr></div>
+';
 
 1;
diff --git a/tp/t/results/coverage_braces/two_footnotes_in_nodes.pl 
b/tp/t/results/coverage_braces/two_footnotes_in_nodes.pl
index 26a7621..9cd542f 100644
--- a/tp/t/results/coverage_braces/two_footnotes_in_nodes.pl
+++ b/tp/t/results/coverage_braces/two_footnotes_in_nodes.pl
@@ -869,6 +869,8 @@ Previous: <a href="#Top" accesskey="p" rel="prev">2 
footnotes in 2 nodes</a>, Up
 </p>
 <p>D<a id="DOCF4" href="#FOOT4"><sup>4</sup></a>
 </p>
+</div>
+</div>
 <div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
@@ -891,8 +893,6 @@ Previous: <a href="#Top" accesskey="p" rel="prev">2 
footnotes in 2 nodes</a>, Up
 <p>para2</p>
 </div>
 <hr>
-</div>
-</div>
 
 
 
@@ -1030,6 +1030,8 @@ 
$result_converted{'html_text'}->{'two_footnotes_in_nodes'} = '<div class="top" i
 </p>
 <p>D<a id="DOCF4" href="#FOOT4"><sup>4</sup></a>
 </p>
+</div>
+</div>
 <div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
diff --git a/tp/t/results/coverage_braces/two_footnotes_in_nodes_separate.pl 
b/tp/t/results/coverage_braces/two_footnotes_in_nodes_separate.pl
index 6506924..0f58e41 100644
--- a/tp/t/results/coverage_braces/two_footnotes_in_nodes_separate.pl
+++ b/tp/t/results/coverage_braces/two_footnotes_in_nodes_separate.pl
@@ -905,9 +905,9 @@ Previous: <a href="#Top" accesskey="p" rel="prev">2 
footnotes in 2 nodes</a>, Up
 </p>
 <p>D<a id="DOCF4" href="#FOOT4"><sup>4</sup></a>
 </p>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
@@ -1045,6 +1045,8 @@ 
$result_converted{'html_text'}->{'two_footnotes_in_nodes_separate'} = '<div clas
 </p>
 <p>D<a id="DOCF4" href="#FOOT4"><sup>4</sup></a>
 </p>
+</div>
+</div>
 <hr>
 ';
 
diff --git a/tp/t/results/float/complex_float.pl 
b/tp/t/results/float/complex_float.pl
index d5ab86f..e1845b4 100644
--- a/tp/t/results/float/complex_float.pl
+++ b/tp/t/results/float/complex_float.pl
@@ -5069,6 +5069,8 @@ A footnote 2.
 </p></div></div>
 <p>See <a href="#text-with-a-lot-of-features">Text 1</a>.
 </p>
+</div>
+</div>
 <div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
@@ -5083,8 +5085,6 @@ A footnote 2.
 <p>footnote Text with features caption 2</p>
 </div>
 <hr>
-</div>
-</div>
 
 
 
diff --git a/tp/t/results/float/float_copying.pl 
b/tp/t/results/float/float_copying.pl
index 66146f3..20c6c5b 100644
--- a/tp/t/results/float/float_copying.pl
+++ b/tp/t/results/float/float_copying.pl
@@ -1728,6 +1728,8 @@ the author abandon his copyright.
 <a class="summary-letter" href="#Copying-and-floats_fn_letter-P"><b>P</b></a>
  &nbsp; 
 </td></tr></table>
+</div>
+</div>
 <div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
@@ -1764,8 +1766,6 @@ the author abandon his copyright.
 </p>
 </div>
 <hr>
-</div>
-</div>
 
 
 
diff --git a/tp/t/results/float/numbering_captions_listoffloats.pl 
b/tp/t/results/float/numbering_captions_listoffloats.pl
index 9af9ad3..cad3599 100644
--- a/tp/t/results/float/numbering_captions_listoffloats.pl
+++ b/tp/t/results/float/numbering_captions_listoffloats.pl
@@ -8481,9 +8481,9 @@ See <a href="#text-with-a-lot-of-features">Text 1</a>.
 <dt><a href="#theoreme">th&eacute;or&egrave;me 1.1</a></dt><dd><p>C A 
th&eacute;or&egrave;me</p></dd>
 </dl>
 
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git 
a/tp/t/results/formatting/float_copying/res_html/Copying-and-floats.html 
b/tp/t/results/formatting/float_copying/res_html/Copying-and-floats.html
index b24d119..fe78da7 100644
--- a/tp/t/results/formatting/float_copying/res_html/Copying-and-floats.html
+++ b/tp/t/results/formatting/float_copying/res_html/Copying-and-floats.html
@@ -147,6 +147,7 @@ the author abandon his copyright.
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -161,7 +162,6 @@ the author abandon his copyright.
 <td valign="middle" align="left">[<a href="#Copying-and-floats" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="float_copying_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/formatting/float_copying/res_html/index.html 
b/tp/t/results/formatting/float_copying/res_html/index.html
index 695536f..d3fe8b0 100644
--- a/tp/t/results/formatting/float_copying/res_html/index.html
+++ b/tp/t/results/formatting/float_copying/res_html/index.html
@@ -77,6 +77,7 @@ the author abandon his copyright.
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -86,7 +87,6 @@ the author abandon his copyright.
 <td valign="middle" align="left">[<a href="Copying-and-floats.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="float_copying_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/formatting/texi_bib_example.pl 
b/tp/t/results/formatting/texi_bib_example.pl
index 31b3526..a73ef63 100644
--- a/tp/t/results/formatting/texi_bib_example.pl
+++ b/tp/t/results/formatting/texi_bib_example.pl
@@ -5754,9 +5754,9 @@ Massachusetts, 1994.
 
 </li></ul>
 
-<hr>
 </div>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/formatting/texi_glossary.pl 
b/tp/t/results/formatting/texi_glossary.pl
index d3d982f..4f3ce9d 100644
--- a/tp/t/results/formatting/texi_glossary.pl
+++ b/tp/t/results/formatting/texi_glossary.pl
@@ -1655,9 +1655,9 @@ ul.no-bullet {list-style: none}
 <p>name2 <span id="id2"></span>text2
 </p>
 
-<hr>
 </div>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/html_tests/character_number_leading_toc_stoc.pl 
b/tp/t/results/html_tests/character_number_leading_toc_stoc.pl
index 8a582c1..42e7ee6 100644
--- a/tp/t/results/html_tests/character_number_leading_toc_stoc.pl
+++ b/tp/t/results/html_tests/character_number_leading_toc_stoc.pl
@@ -337,7 +337,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><h1 class="top">top</h1>
+<div class="top" id="top">
+<h1 class="top">top</h1>
 <div class="Contents_element" id="SEC_Contents">
 <h2 class="contents-heading">Table of Contents</h2>
 
@@ -362,16 +363,23 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
-<span id="g_t0"></span><h2 class="chapter">1 0</h2>
-<span id="g_t_005f"></span><h2 class="unnumbered">_</h2>
+<div class="chapter" id="g_t0">
+<h2 class="chapter">1 0</h2>
+</div>
+<div class="unnumbered" id="g_t_005f">
+<h2 class="unnumbered">_</h2>
 <ul class="section-toc">
 <li><a href="#g_t_003f" accesskey="1">?</a></li>
 </ul>
-<span id="g_t_003f"></span><h3 class="section">?</h3>
+<div class="section" id="g_t_003f">
+<h3 class="section">?</h3>
+
 
 
+<hr></div>
+</div>
+</div>
 
-<hr>
 
 
 </body>
diff --git a/tp/t/results/html_tests/check_htmlxref.pl 
b/tp/t/results/html_tests/check_htmlxref.pl
index f340297..a6e221a 100644
--- a/tp/t/results/html_tests/check_htmlxref.pl
+++ b/tp/t/results/html_tests/check_htmlxref.pl
@@ -869,8 +869,8 @@ Next: <a href="no_existing_no_manual_direction.html#Top" 
accesskey="n" rel="next
 Next: <a href="no_existing_no_manual.html#Top" accesskey="n" 
rel="next">(no_existing_no_manual.info)</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">first</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/html_tests/documentdescription.pl 
b/tp/t/results/html_tests/documentdescription.pl
index 164b880..2fa27fc 100644
--- a/tp/t/results/html_tests/documentdescription.pl
+++ b/tp/t/results/html_tests/documentdescription.pl
@@ -445,8 +445,10 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 
-<span id="top"></span><h1 class="top">top</h1>
-<hr>
+<div class="top" id="top">
+<h1 class="top">top</h1>
+<hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/html_tests/index_and_node_same_name.pl 
b/tp/t/results/html_tests/index_and_node_same_name.pl
index a7aa7f1..d6d2fee 100644
--- a/tp/t/results/html_tests/index_and_node_same_name.pl
+++ b/tp/t/results/html_tests/index_and_node_same_name.pl
@@ -288,7 +288,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><h1 class="top">top</h1>
+<div class="top" id="top">
+<h1 class="top">top</h1>
 <span id="index-node"></span><h4 class="node-heading">index node</h4>
 
 <span id="index-node-1"></span>
@@ -306,7 +307,8 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
-<hr>
+<hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/html_tests/index_below.pl 
b/tp/t/results/html_tests/index_below.pl
index 08c338c..7cef219 100644
--- a/tp/t/results/html_tests/index_below.pl
+++ b/tp/t/results/html_tests/index_below.pl
@@ -463,7 +463,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><div class="header">
+<div class="top" id="top">
+<div class="header">
 <p>
  &nbsp; [<a href="#chap" title="Index" rel="index">Index</a>]</p>
 </div>
@@ -473,7 +474,8 @@ ul.no-bullet {list-style: none}
 <li><a href="#chap" accesskey="1">chap</a></li>
 </ul>
 <hr>
-<span id="chap"></span><div class="header">
+<div class="chapter" id="chap">
+<div class="header">
 <p>
  Up : <a href="#top" accesskey="u" rel="up">top</a> &nbsp; [<a href="#chap" 
title="Index" rel="index">Index</a>]</p>
 </div>
@@ -483,7 +485,8 @@ ul.no-bullet {list-style: none}
 <li><a href="#sec" accesskey="1">sec</a></li>
 </ul>
 <hr>
-<span id="sec"></span><div class="header">
+<div class="section" id="sec">
+<div class="header">
 <p>
  Up : <a href="#chap" accesskey="u" rel="up">chap</a> &nbsp; [<a href="#chap" 
title="Index" rel="index">Index</a>]</p>
 </div>
@@ -503,6 +506,9 @@ ul.no-bullet {list-style: none}
 <table><tr><th valign="top">Jump to: &nbsp; </th><td><a class="summary-letter" 
href="#sec_cp_letter-E"><b>E</b></a>
  &nbsp; 
 </td></tr></table>
+</div>
+</div>
+</div>
 <hr>
 
 
diff --git 
a/tp/t/results/html_tests/redirection_same_labels/res_html/circumflex.html 
b/tp/t/results/html_tests/redirection_same_labels/res_html/circumflex.html
index e0078a2..840e4ed 100644
--- a/tp/t/results/html_tests/redirection_same_labels/res_html/circumflex.html
+++ b/tp/t/results/html_tests/redirection_same_labels/res_html/circumflex.html
@@ -52,12 +52,12 @@ Previous: <a href="umlaut.html#umlaut" accesskey="p" 
rel="prev">umlaut</a>, Up:
 Up: <a href="#circumflex" accesskey="u" rel="up">circumflex</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">&icirc;</h4>
+</div>
 <hr>
 <div class="header">
 <p>
 Up: <a href="#circumflex" accesskey="u" rel="up">circumflex</a> &nbsp; </p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/t/results/html_tests/redirection_same_labels/res_html/index.html 
b/tp/t/results/html_tests/redirection_same_labels/res_html/index.html
index 1bfd6dd..8103636 100644
--- a/tp/t/results/html_tests/redirection_same_labels/res_html/index.html
+++ b/tp/t/results/html_tests/redirection_same_labels/res_html/index.html
@@ -50,12 +50,12 @@ Next: <a href="umlaut.html#umlaut" accesskey="n" 
rel="next">umlaut</a> &nbsp; </
 <li><a href="umlaut.html#umlaut" accesskey="1">umlaut</a></li>
 <li><a href="circumflex.html#circumflex" accesskey="2">circumflex</a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="umlaut.html#umlaut" accesskey="n" rel="next">umlaut</a> &nbsp; 
</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/t/results/html_tests/redirection_same_labels/res_html/umlaut.html 
b/tp/t/results/html_tests/redirection_same_labels/res_html/umlaut.html
index 65ed5ec..2dcfec5 100644
--- a/tp/t/results/html_tests/redirection_same_labels/res_html/umlaut.html
+++ b/tp/t/results/html_tests/redirection_same_labels/res_html/umlaut.html
@@ -61,12 +61,12 @@ Previous: <a href="#g_t_00ef" accesskey="p" 
rel="prev">&iuml;</a>, Up: <a href="
 </div>
 <h4 class="node-heading">&#297;</h4>
 
+</div>
 <hr>
 <div class="header">
 <p>
 Previous: <a href="#g_t_00ef" accesskey="p" rel="prev">&iuml;</a>, Up: <a 
href="#umlaut" accesskey="u" rel="up">umlaut</a> &nbsp; </p>
 </div>
-</div>
 
 
 
diff --git a/tp/t/results/html_tests/shortcontents_no_top.pl 
b/tp/t/results/html_tests/shortcontents_no_top.pl
index 5396f7e..1d7f3a4 100644
--- a/tp/t/results/html_tests/shortcontents_no_top.pl
+++ b/tp/t/results/html_tests/shortcontents_no_top.pl
@@ -269,14 +269,18 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="chap"></span><h2 class="chapter">1 chap</h2>
+<div class="chapter" id="chap">
+<h2 class="chapter">1 chap</h2>
 
-<span id="chap2"></span><h2 class="chapter">2 chap2</h2>
+</div>
+<div class="chapter" id="chap2">
+<h2 class="chapter">2 chap2</h2>
 
 <ul class="section-toc">
 <li><a href="#sec" accesskey="1">sec</a></li>
 </ul>
-<span id="sec"></span><h3 class="section">2.1 sec</h3>
+<div class="section" id="sec">
+<h3 class="section">2.1 sec</h3>
 
 <div class="Overview_element" id="SEC_Overview">
 <h2 class="shortcontents-heading">Short Table of Contents</h2>
@@ -289,7 +293,9 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
-<hr>
+<hr></div>
+</div>
+
 
 
 </body>
diff --git a/tp/t/results/html_tests/test_xrefautomaticsectiontitle.pl 
b/tp/t/results/html_tests/test_xrefautomaticsectiontitle.pl
index 7be5d51..9ed62aa 100644
--- a/tp/t/results/html_tests/test_xrefautomaticsectiontitle.pl
+++ b/tp/t/results/html_tests/test_xrefautomaticsectiontitle.pl
@@ -733,9 +733,9 @@ Previous: <a href="#Top" accesskey="p" rel="prev">Top</a>, 
Up: <a href="#Top" ac
 </p>
 
 <p>See <a href="#chap">chap</a>.
-</p><hr>
-</div>
+</p></div>
 </div>
+<hr>
 
 
 
diff --git 
a/tp/t/results/html_tests/text_before_top_and_contents_after_title.pl 
b/tp/t/results/html_tests/text_before_top_and_contents_after_title.pl
index ad689e8..306ed6d 100644
--- a/tp/t/results/html_tests/text_before_top_and_contents_after_title.pl
+++ b/tp/t/results/html_tests/text_before_top_and_contents_after_title.pl
@@ -378,10 +378,12 @@ ul.no-bullet {list-style: none}
 <ul class="section-toc">
 <li><a href="#the-chap" accesskey="1">the chap</a></li>
 </ul>
-<span id="the-chap"></span><h2 class="chapter">1 the chap</h2>
+<div class="chapter" id="the-chap">
+<h2 class="chapter">1 the chap</h2>
 
 
 <hr></div>
+</div>
 
 
 
diff --git a/tp/t/results/htmlxref/htmlxref_nodes/res_html/index.html 
b/tp/t/results/htmlxref/htmlxref_nodes/res_html/index.html
index 4b69e35..b15e2b8 100644
--- a/tp/t/results/htmlxref/htmlxref_nodes/res_html/index.html
+++ b/tp/t/results/htmlxref/htmlxref_nodes/res_html/index.html
@@ -109,6 +109,7 @@ split: ../doc/node.html#node
 <pre class="example">target: #local-node
 </pre></div>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -118,7 +119,6 @@ split: ../doc/node.html#node
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="test_refs_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/htmlxref/htmlxref_nodes/res_html/other-nodes.html 
b/tp/t/results/htmlxref/htmlxref_nodes/res_html/other-nodes.html
index 87b4c2e..c641ad4 100644
--- a/tp/t/results/htmlxref/htmlxref_nodes/res_html/other-nodes.html
+++ b/tp/t/results/htmlxref/htmlxref_nodes/res_html/other-nodes.html
@@ -73,8 +73,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/htmlxref/htmlxref_only_mono_nodes/res_html/index.html 
b/tp/t/results/htmlxref/htmlxref_only_mono_nodes/res_html/index.html
index 35237eb..6d70b2f 100644
--- a/tp/t/results/htmlxref/htmlxref_only_mono_nodes/res_html/index.html
+++ b/tp/t/results/htmlxref/htmlxref_only_mono_nodes/res_html/index.html
@@ -109,6 +109,7 @@ split: ../doc/node.html#node
 <pre class="example">target: #local-node
 </pre></div>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -118,7 +119,6 @@ split: ../doc/node.html#node
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="test_refs_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/htmlxref/htmlxref_only_mono_nodes/res_html/other-nodes.html 
b/tp/t/results/htmlxref/htmlxref_only_mono_nodes/res_html/other-nodes.html
index 87b4c2e..c641ad4 100644
--- a/tp/t/results/htmlxref/htmlxref_only_mono_nodes/res_html/other-nodes.html
+++ b/tp/t/results/htmlxref/htmlxref_only_mono_nodes/res_html/other-nodes.html
@@ -73,8 +73,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/htmlxref/htmlxref_only_split_nodes/res_html/index.html 
b/tp/t/results/htmlxref/htmlxref_only_split_nodes/res_html/index.html
index 4b69e35..b15e2b8 100644
--- a/tp/t/results/htmlxref/htmlxref_only_split_nodes/res_html/index.html
+++ b/tp/t/results/htmlxref/htmlxref_only_split_nodes/res_html/index.html
@@ -109,6 +109,7 @@ split: ../doc/node.html#node
 <pre class="example">target: #local-node
 </pre></div>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -118,7 +119,6 @@ split: ../doc/node.html#node
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="test_refs_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/htmlxref/htmlxref_only_split_nodes/res_html/other-nodes.html 
b/tp/t/results/htmlxref/htmlxref_only_split_nodes/res_html/other-nodes.html
index 87b4c2e..c641ad4 100644
--- a/tp/t/results/htmlxref/htmlxref_only_split_nodes/res_html/other-nodes.html
+++ b/tp/t/results/htmlxref/htmlxref_only_split_nodes/res_html/other-nodes.html
@@ -73,8 +73,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/indices/printindex_index_entry_in_copying.pl 
b/tp/t/results/indices/printindex_index_entry_in_copying.pl
index d1896a5..1dde4f1 100644
--- a/tp/t/results/indices/printindex_index_entry_in_copying.pl
+++ b/tp/t/results/indices/printindex_index_entry_in_copying.pl
@@ -1547,6 +1547,8 @@ 
$result_converted{'html_text'}->{'printindex_index_entry_in_copying'} = '
  &nbsp; 
 </td></tr></table>
 
+</div>
+</div>
 <hr>
 ';
 
diff --git 
a/tp/t/results/indices/printindex_index_entry_in_copying_in_footnote.pl 
b/tp/t/results/indices/printindex_index_entry_in_copying_in_footnote.pl
index bb20632..12b0b56 100644
--- a/tp/t/results/indices/printindex_index_entry_in_copying_in_footnote.pl
+++ b/tp/t/results/indices/printindex_index_entry_in_copying_in_footnote.pl
@@ -946,6 +946,8 @@ 
$result_converted{'html_text'}->{'printindex_index_entry_in_copying_in_footnote'
 </td></tr></table>
 
 
+</div>
+</div>
 <div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
diff --git 
a/tp/t/results/indices/printindex_index_entry_in_copying_no_insertcopying.pl 
b/tp/t/results/indices/printindex_index_entry_in_copying_no_insertcopying.pl
index e2bf8cf..d46e286 100644
--- a/tp/t/results/indices/printindex_index_entry_in_copying_no_insertcopying.pl
+++ b/tp/t/results/indices/printindex_index_entry_in_copying_no_insertcopying.pl
@@ -1347,6 +1347,8 @@ 
$result_converted{'html_text'}->{'printindex_index_entry_in_copying_no_insertcop
  &nbsp; 
 </td></tr></table>
 
+</div>
+</div>
 <hr>
 ';
 
diff --git a/tp/t/results/languages/appendix_translated.pl 
b/tp/t/results/languages/appendix_translated.pl
index a673fc3..978cccf 100644
--- a/tp/t/results/languages/appendix_translated.pl
+++ b/tp/t/results/languages/appendix_translated.pl
@@ -382,9 +382,11 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
-<span id="dernier"></span><h2 class="appendix">Annexe A dernier</h2>
+<div class="appendix" id="dernier">
+<h2 class="appendix">Annexe A dernier</h2>
 
 <hr></div>
+</div>
 
 
 
diff --git 
a/tp/t/results/languages/multiple_lang_chapters/res_html/multiple_lang_chapters.html
 
b/tp/t/results/languages/multiple_lang_chapters/res_html/multiple_lang_chapters.html
index 795e28b..53df021 100644
--- 
a/tp/t/results/languages/multiple_lang_chapters/res_html/multiple_lang_chapters.html
+++ 
b/tp/t/results/languages/multiple_lang_chapters/res_html/multiple_lang_chapters.html
@@ -112,9 +112,9 @@ Anterior: <a href="#chapter-de" accesskey="p" 
rel="prev">de</a>, Acima: <a href=
 <span id="pt_005fbR"></span><h2 class="chapter">5 pt_bR</h2>
 
 <p>In brazilian. Veja <a href="#Top">Multi language file</a>.
-</p><hr>
-</div>
+</p></div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/layout/navigation_chapter/res_html/chapter.html 
b/tp/t/results/layout/navigation_chapter/res_html/chapter.html
index a9e038c..c98beb9 100644
--- a/tp/t/results/layout/navigation_chapter/res_html/chapter.html
+++ b/tp/t/results/layout/navigation_chapter/res_html/chapter.html
@@ -130,6 +130,9 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <span id="Sub-section-in-section"></span><h3 class="subsection">1.1.1 Sub 
section in section</h3>
 
 
+</div>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -144,9 +147,6 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_chapter/res_html/index.html 
b/tp/t/results/layout/navigation_chapter/res_html/index.html
index 8037ed5..2c44f65 100644
--- a/tp/t/results/layout/navigation_chapter/res_html/index.html
+++ b/tp/t/results/layout/navigation_chapter/res_html/index.html
@@ -53,6 +53,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -62,7 +63,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_chapter_no_header/res_html/chapter.html 
b/tp/t/results/layout/navigation_chapter_no_header/res_html/chapter.html
index 43c1457..f7e8f82 100644
--- a/tp/t/results/layout/navigation_chapter_no_header/res_html/chapter.html
+++ b/tp/t/results/layout/navigation_chapter_no_header/res_html/chapter.html
@@ -99,6 +99,9 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  bb 
 b bb.
 <span id="Sub-section-in-section"></span><h3 class="subsection">1.1.1 Sub 
section in section</h3>
 
 
+</div>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -113,9 +116,6 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_chapter_no_header/res_html/index.html 
b/tp/t/results/layout/navigation_chapter_no_header/res_html/index.html
index 8037ed5..2c44f65 100644
--- a/tp/t/results/layout/navigation_chapter_no_header/res_html/index.html
+++ b/tp/t/results/layout/navigation_chapter_no_header/res_html/index.html
@@ -53,6 +53,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -62,7 +63,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_chapter_no_header_vertical/res_html/chapter.html
 
b/tp/t/results/layout/navigation_chapter_no_header_vertical/res_html/chapter.html
index 5ef4338..2ad6952 100644
--- 
a/tp/t/results/layout/navigation_chapter_no_header_vertical/res_html/chapter.html
+++ 
b/tp/t/results/layout/navigation_chapter_no_header_vertical/res_html/chapter.html
@@ -128,6 +128,9 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 </td>
 </tr>
 </table>
+</div>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -142,9 +145,6 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_chapter_no_header_vertical/res_html/index.html 
b/tp/t/results/layout/navigation_chapter_no_header_vertical/res_html/index.html
index c7dd9d9..456f240 100644
--- 
a/tp/t/results/layout/navigation_chapter_no_header_vertical/res_html/index.html
+++ 
b/tp/t/results/layout/navigation_chapter_no_header_vertical/res_html/index.html
@@ -73,6 +73,7 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -82,7 +83,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_chapter_vertical/res_html/chapter.html 
b/tp/t/results/layout/navigation_chapter_vertical/res_html/chapter.html
index 1c622d7..5830573 100644
--- a/tp/t/results/layout/navigation_chapter_vertical/res_html/chapter.html
+++ b/tp/t/results/layout/navigation_chapter_vertical/res_html/chapter.html
@@ -164,6 +164,9 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 </td>
 </tr>
 </table>
+</div>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -178,9 +181,6 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_chapter_vertical/res_html/index.html 
b/tp/t/results/layout/navigation_chapter_vertical/res_html/index.html
index c7dd9d9..456f240 100644
--- a/tp/t/results/layout/navigation_chapter_vertical/res_html/index.html
+++ b/tp/t/results/layout/navigation_chapter_vertical/res_html/index.html
@@ -73,6 +73,7 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -82,7 +83,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_node/res_html/chapter.html 
b/tp/t/results/layout/navigation_node/res_html/chapter.html
index df0a987..f65cfe0 100644
--- a/tp/t/results/layout/navigation_node/res_html/chapter.html
+++ b/tp/t/results/layout/navigation_node/res_html/chapter.html
@@ -60,8 +60,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_node/res_html/index.html 
b/tp/t/results/layout/navigation_node/res_html/index.html
index 8f32456..43416d4 100644
--- a/tp/t/results/layout/navigation_node/res_html/index.html
+++ b/tp/t/results/layout/navigation_node/res_html/index.html
@@ -54,6 +54,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -63,7 +64,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_node/res_html/section.html 
b/tp/t/results/layout/navigation_node/res_html/section.html
index 59c64ca..e5e8502 100644
--- a/tp/t/results/layout/navigation_node/res_html/section.html
+++ b/tp/t/results/layout/navigation_node/res_html/section.html
@@ -87,8 +87,8 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  bb 
 b bb.
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_node/res_html/subsection.html 
b/tp/t/results/layout/navigation_node/res_html/subsection.html
index 49141cb..ca3ad5f 100644
--- a/tp/t/results/layout/navigation_node/res_html/subsection.html
+++ b/tp/t/results/layout/navigation_node/res_html/subsection.html
@@ -56,8 +56,8 @@ ul.no-bullet {list-style: none}
 <span id="Sub-section-in-section"></span><h3 class="subsection">1.1.1 Sub 
section in section</h3>
 
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_node_no_header/res_html/index.html 
b/tp/t/results/layout/navigation_node_no_header/res_html/index.html
index 4c67290..e7bb667 100644
--- a/tp/t/results/layout/navigation_node_no_header/res_html/index.html
+++ b/tp/t/results/layout/navigation_node_no_header/res_html/index.html
@@ -54,8 +54,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_node_no_header_vertical/res_html/index.html 
b/tp/t/results/layout/navigation_node_no_header_vertical/res_html/index.html
index a5f89fe..d30405e 100644
--- a/tp/t/results/layout/navigation_node_no_header_vertical/res_html/index.html
+++ b/tp/t/results/layout/navigation_node_no_header_vertical/res_html/index.html
@@ -73,8 +73,8 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_node_vertical/res_html/chapter.html 
b/tp/t/results/layout/navigation_node_vertical/res_html/chapter.html
index bdfd175..f77d0ac 100644
--- a/tp/t/results/layout/navigation_node_vertical/res_html/chapter.html
+++ b/tp/t/results/layout/navigation_node_vertical/res_html/chapter.html
@@ -93,8 +93,8 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_node_vertical/res_html/index.html 
b/tp/t/results/layout/navigation_node_vertical/res_html/index.html
index bc6a9ff..158ee36 100644
--- a/tp/t/results/layout/navigation_node_vertical/res_html/index.html
+++ b/tp/t/results/layout/navigation_node_vertical/res_html/index.html
@@ -73,6 +73,7 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -82,7 +83,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_node_vertical/res_html/section.html 
b/tp/t/results/layout/navigation_node_vertical/res_html/section.html
index 47d0438..fd3779b 100644
--- a/tp/t/results/layout/navigation_node_vertical/res_html/section.html
+++ b/tp/t/results/layout/navigation_node_vertical/res_html/section.html
@@ -120,8 +120,8 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 </td>
 </tr>
 </table>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_node_vertical/res_html/subsection.html 
b/tp/t/results/layout/navigation_node_vertical/res_html/subsection.html
index f03bcf3..a878188 100644
--- a/tp/t/results/layout/navigation_node_vertical/res_html/subsection.html
+++ b/tp/t/results/layout/navigation_node_vertical/res_html/subsection.html
@@ -89,8 +89,8 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_section/res_html/chapter.html 
b/tp/t/results/layout/navigation_section/res_html/chapter.html
index e3031ad..5edf4ae 100644
--- a/tp/t/results/layout/navigation_section/res_html/chapter.html
+++ b/tp/t/results/layout/navigation_section/res_html/chapter.html
@@ -59,6 +59,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -67,7 +68,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="section.html#section" title="Next 
section in reading order"> &gt; </a>]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_section/res_html/index.html 
b/tp/t/results/layout/navigation_section/res_html/index.html
index 77b5222..8d4278f 100644
--- a/tp/t/results/layout/navigation_section/res_html/index.html
+++ b/tp/t/results/layout/navigation_section/res_html/index.html
@@ -53,6 +53,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -62,7 +63,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/navigation_section/res_html/section.html 
b/tp/t/results/layout/navigation_section/res_html/section.html
index f913270..d32c84e 100644
--- a/tp/t/results/layout/navigation_section/res_html/section.html
+++ b/tp/t/results/layout/navigation_section/res_html/section.html
@@ -106,6 +106,8 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <span id="Sub-section-in-section"></span><h3 class="subsection">1.1.1 Sub 
section in section</h3>
 
 
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -114,8 +116,6 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <td valign="middle" align="left">[ &gt; ]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_no_header/res_html/chapter.html 
b/tp/t/results/layout/navigation_section_no_header/res_html/chapter.html
index e3031ad..5edf4ae 100644
--- a/tp/t/results/layout/navigation_section_no_header/res_html/chapter.html
+++ b/tp/t/results/layout/navigation_section_no_header/res_html/chapter.html
@@ -59,6 +59,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -67,7 +68,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="section.html#section" title="Next 
section in reading order"> &gt; </a>]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_no_header/res_html/index.html 
b/tp/t/results/layout/navigation_section_no_header/res_html/index.html
index 77b5222..8d4278f 100644
--- a/tp/t/results/layout/navigation_section_no_header/res_html/index.html
+++ b/tp/t/results/layout/navigation_section_no_header/res_html/index.html
@@ -53,6 +53,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -62,7 +63,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_no_header/res_html/section.html 
b/tp/t/results/layout/navigation_section_no_header/res_html/section.html
index 97e34a6..b3419b5 100644
--- a/tp/t/results/layout/navigation_section_no_header/res_html/section.html
+++ b/tp/t/results/layout/navigation_section_no_header/res_html/section.html
@@ -91,6 +91,8 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  bb 
 b bb.
 <span id="Sub-section-in-section"></span><h3 class="subsection">1.1.1 Sub 
section in section</h3>
 
 
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -99,8 +101,6 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <td valign="middle" align="left">[ &gt; ]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_no_header_vertical/res_html/chapter.html
 
b/tp/t/results/layout/navigation_section_no_header_vertical/res_html/chapter.html
index 3d0dc6d..05c2b1e 100644
--- 
a/tp/t/results/layout/navigation_section_no_header_vertical/res_html/chapter.html
+++ 
b/tp/t/results/layout/navigation_section_no_header_vertical/res_html/chapter.html
@@ -93,6 +93,7 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -101,7 +102,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="section.html#section" title="Next 
section in reading order"> &gt; </a>]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_no_header_vertical/res_html/index.html 
b/tp/t/results/layout/navigation_section_no_header_vertical/res_html/index.html
index bc6a9ff..158ee36 100644
--- 
a/tp/t/results/layout/navigation_section_no_header_vertical/res_html/index.html
+++ 
b/tp/t/results/layout/navigation_section_no_header_vertical/res_html/index.html
@@ -73,6 +73,7 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -82,7 +83,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_no_header_vertical/res_html/section.html
 
b/tp/t/results/layout/navigation_section_no_header_vertical/res_html/section.html
index 8d6a9c9..1e5cf78 100644
--- 
a/tp/t/results/layout/navigation_section_no_header_vertical/res_html/section.html
+++ 
b/tp/t/results/layout/navigation_section_no_header_vertical/res_html/section.html
@@ -125,6 +125,8 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 </td>
 </tr>
 </table>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -133,8 +135,6 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <td valign="middle" align="left">[ &gt; ]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_vertical/res_html/chapter.html 
b/tp/t/results/layout/navigation_section_vertical/res_html/chapter.html
index 3d0dc6d..05c2b1e 100644
--- a/tp/t/results/layout/navigation_section_vertical/res_html/chapter.html
+++ b/tp/t/results/layout/navigation_section_vertical/res_html/chapter.html
@@ -93,6 +93,7 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -101,7 +102,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="section.html#section" title="Next 
section in reading order"> &gt; </a>]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_vertical/res_html/index.html 
b/tp/t/results/layout/navigation_section_vertical/res_html/index.html
index bc6a9ff..158ee36 100644
--- a/tp/t/results/layout/navigation_section_vertical/res_html/index.html
+++ b/tp/t/results/layout/navigation_section_vertical/res_html/index.html
@@ -73,6 +73,7 @@ ul.no-bullet {list-style: none}
 </td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -82,7 +83,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="navigation_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/layout/navigation_section_vertical/res_html/section.html 
b/tp/t/results/layout/navigation_section_vertical/res_html/section.html
index 32e0a92..72621a4 100644
--- a/tp/t/results/layout/navigation_section_vertical/res_html/section.html
+++ b/tp/t/results/layout/navigation_section_vertical/res_html/section.html
@@ -140,6 +140,8 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 </td>
 </tr>
 </table>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -148,8 +150,6 @@ b b b b b b b b b b b b b b b b  b b b b b bb b b b b b b  
bb  b bb.
 <td valign="middle" align="left">[ &gt; ]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/layout/no_monolithic/res_html/no_monolithic.html 
b/tp/t/results/layout/no_monolithic/res_html/no_monolithic.html
index 87682ec..2dfd18a 100644
--- a/tp/t/results/layout/no_monolithic/res_html/no_monolithic.html
+++ b/tp/t/results/layout/no_monolithic/res_html/no_monolithic.html
@@ -92,9 +92,9 @@ ul.no-bullet {list-style: none}
 <table><tr><th valign="top">Jump to: &nbsp; </th><td><a class="summary-letter" 
href="#Chapter_cp_letter-T"><b>T</b></a>
  &nbsp; 
 </td></tr></table>
-<hr>
 </div>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/menu/comment_on_menu_line.pl 
b/tp/t/results/menu/comment_on_menu_line.pl
index a2ac7d5..efd1ed8 100644
--- a/tp/t/results/menu/comment_on_menu_line.pl
+++ b/tp/t/results/menu/comment_on_menu_line.pl
@@ -484,8 +484,8 @@ Next: <a href="#first" accesskey="n" rel="next">first</a> 
&nbsp; </p>
 Previous: <a href="#Top" accesskey="p" rel="prev">first</a>, Up: <a 
href="#Top" accesskey="u" rel="up">first</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">first</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/menu/detailmenu_on_subnodes.pl 
b/tp/t/results/menu/detailmenu_on_subnodes.pl
index 62ecade..bcbdcde 100644
--- a/tp/t/results/menu/detailmenu_on_subnodes.pl
+++ b/tp/t/results/menu/detailmenu_on_subnodes.pl
@@ -2055,10 +2055,10 @@ Next: <a href="#unnumberedsec" accesskey="n" 
rel="next">unnumberedsec</a>, Up: <
 Previous: <a href="#section-chap-2" accesskey="p" rel="prev">section chap 
2</a>, Up: <a href="#chapter-2" accesskey="u" rel="up">chapter 2</a> &nbsp; </p>
 </div>
 <span id="unnumberedsec-1"></span><h3 class="unnumberedsec">unnumberedsec</h3>
-<hr>
 </div>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/misc_commands/no_empty_line_between_headings.pl 
b/tp/t/results/misc_commands/no_empty_line_between_headings.pl
index eddc4b6..f96a7a8 100644
--- a/tp/t/results/misc_commands/no_empty_line_between_headings.pl
+++ b/tp/t/results/misc_commands/no_empty_line_between_headings.pl
@@ -233,17 +233,23 @@ Subheading
 ';
 
 
-$result_converted{'html_text'}->{'no_empty_line_between_headings'} = '<span 
id="Top"></span><h1 class="top">Top</h1>
+$result_converted{'html_text'}->{'no_empty_line_between_headings'} = '<div 
class="top" id="Top">
+<h1 class="top">Top</h1>
 <span id="Subheading"></span><h4 class="subheading">Subheading</h4>
 <ul class="section-toc">
 <li><a href="#Chapter" accesskey="1">Chapter</a></li>
 </ul>
-<span id="Chapter"></span><h2 class="chapter">1 Chapter</h2>
+<div class="chapter" id="Chapter">
+<h2 class="chapter">1 Chapter</h2>
 <ul class="section-toc">
 <li><a href="#Section" accesskey="1">Section</a></li>
 </ul>
-<span id="Section"></span><h3 class="section">1.1 Section</h3>
-<hr>';
+<div class="section" id="Section">
+<h3 class="section">1.1 Section</h3>
+<hr></div>
+</div>
+</div>
+';
 
 
 $result_converted{'docbook'}->{'no_empty_line_between_headings'} = '<chapter 
label="">
diff --git a/tp/t/results/morecoverage/formatting_fr.pl 
b/tp/t/results/morecoverage/formatting_fr.pl
index e8f0ddd..a4c76c4 100644
--- a/tp/t/results/morecoverage/formatting_fr.pl
+++ b/tp/t/results/morecoverage/formatting_fr.pl
@@ -5284,9 +5284,9 @@ Menu comment
  &nbsp; 
 </td></tr></table>
 
-<hr>
 </div>
 </div>
+<hr>
 <p><font size="-1">
   Ce document a &eacute;t&eacute; g&eacute;n&eacute;r&eacute; le <em>a sunny 
day</em>.
 </font></p>
diff --git a/tp/t/results/morecoverage/texi_formatting.pl 
b/tp/t/results/morecoverage/texi_formatting.pl
index e68da56..3742916 100644
--- a/tp/t/results/morecoverage/texi_formatting.pl
+++ b/tp/t/results/morecoverage/texi_formatting.pl
@@ -5208,6 +5208,8 @@ Previous: <a href="#chapter" accesskey="p" 
rel="prev">chapter</a>, Up: <a href="
  &nbsp; 
 </td></tr></table>
 
+</div>
+</div>
 <div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
@@ -5216,8 +5218,6 @@ Previous: <a href="#chapter" accesskey="p" 
rel="prev">chapter</a>, Up: <a href="
 <p>in footnote</p>
 </div>
 <hr>
-</div>
-</div>
 
 
 
diff --git a/tp/t/results/moreindices/index_no_node/res_html/Chapter-2.html 
b/tp/t/results/moreindices/index_no_node/res_html/Chapter-2.html
index 5bc5e5f..36a4d7e 100644
--- a/tp/t/results/moreindices/index_no_node/res_html/Chapter-2.html
+++ b/tp/t/results/moreindices/index_no_node/res_html/Chapter-2.html
@@ -36,7 +36,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="Chapter-2"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="chapter" id="Chapter-2">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="Chapter.html" title="Previous 
section in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[ Up ]</td>
@@ -55,6 +56,7 @@ ul.no-bullet {list-style: none}
 
 <p>In chapter 2
 </p>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git a/tp/t/results/moreindices/index_no_node/res_html/Chapter.html 
b/tp/t/results/moreindices/index_no_node/res_html/Chapter.html
index 721b12e..7e0e0c7 100644
--- a/tp/t/results/moreindices/index_no_node/res_html/Chapter.html
+++ b/tp/t/results/moreindices/index_no_node/res_html/Chapter.html
@@ -36,7 +36,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="Chapter"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="chapter" id="Chapter">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html#top-section" 
title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html#second" title="Previous 
section in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[ Up ]</td>
@@ -101,6 +102,7 @@ ul.no-bullet {list-style: none}
 <p>Text of chapter
 <span id="index-Chapter2"></span>
 </p>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html#top-section" 
title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git a/tp/t/results/moreindices/index_no_node/res_html/index.html 
b/tp/t/results/moreindices/index_no_node/res_html/index.html
index 888588a..b45d083 100644
--- a/tp/t/results/moreindices/index_no_node/res_html/index.html
+++ b/tp/t/results/moreindices/index_no_node/res_html/index.html
@@ -36,7 +36,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top-section"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="top" id="top-section">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="unnumbered.html" 
title="Previous section in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#second" title="Next section in 
reading order"> &gt; </a>]</td>
 <td valign="middle" align="left"> &nbsp; </td>
@@ -103,7 +104,8 @@ ul.no-bullet {list-style: none}
 
 
 <hr size="6">
-<span id="second"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+<div class="section" id="second">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#top-section" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#top-section" title="Previous 
section in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#top-section" title="Up section"> 
Up </a>]</td>
@@ -212,6 +214,8 @@ ul.no-bullet {list-style: none}
 <a class="summary-letter" href="#second_cp_letter-U"><b>U</b></a>
  &nbsp; 
 </td></tr></table>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#top-section" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git a/tp/t/results/moreindices/index_no_node/res_html/unnumbered.html 
b/tp/t/results/moreindices/index_no_node/res_html/unnumbered.html
index d02cbdf..e258027 100644
--- a/tp/t/results/moreindices/index_no_node/res_html/unnumbered.html
+++ b/tp/t/results/moreindices/index_no_node/res_html/unnumbered.html
@@ -85,7 +85,8 @@ ul.no-bullet {list-style: none}
 </td></tr></table>
 
 
-<span id="unnumbered"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="unnumbered" id="unnumbered">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt;&lt; ]</td>
 <td valign="middle" align="left">[ &lt; ]</td>
 <td valign="middle" align="left">[ Up ]</td>
@@ -151,6 +152,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt;&lt; ]</td>
diff --git a/tp/t/results/moreindices/index_split/res_html/first.html 
b/tp/t/results/moreindices/index_split/res_html/first.html
index c9dc058..a806a96 100644
--- a/tp/t/results/moreindices/index_split/res_html/first.html
+++ b/tp/t/results/moreindices/index_split/res_html/first.html
@@ -649,6 +649,8 @@ ul.no-bullet {list-style: none}
 <span id="node-3-in-section-3"></span>
 <span id="index-node-3-in-section-3"></span>
 
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#first" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -663,8 +665,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_split_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/index_split/res_html/index.html 
b/tp/t/results/moreindices/index_split/res_html/index.html
index 010d714..f1e87b2 100644
--- a/tp/t/results/moreindices/index_split/res_html/index.html
+++ b/tp/t/results/moreindices/index_split/res_html/index.html
@@ -222,6 +222,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -231,7 +232,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_split_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/index_split/res_html/second-chapter.html 
b/tp/t/results/moreindices/index_split/res_html/second-chapter.html
index 0334f89..cadaccf 100644
--- a/tp/t/results/moreindices/index_split/res_html/second-chapter.html
+++ b/tp/t/results/moreindices/index_split/res_html/second-chapter.html
@@ -56,6 +56,7 @@ ul.no-bullet {list-style: none}
 
 <p>Second chapter
 </p>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="first.html#first" 
title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -70,7 +71,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_split_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/index_split_nodes/res_html/first.html 
b/tp/t/results/moreindices/index_split_nodes/res_html/first.html
index 041f2b9..8169656 100644
--- a/tp/t/results/moreindices/index_split_nodes/res_html/first.html
+++ b/tp/t/results/moreindices/index_split_nodes/res_html/first.html
@@ -177,6 +177,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -193,7 +194,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_split_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/index_split_nodes/res_html/index.html 
b/tp/t/results/moreindices/index_split_nodes/res_html/index.html
index 9d07dbe..e132b79 100644
--- a/tp/t/results/moreindices/index_split_nodes/res_html/index.html
+++ b/tp/t/results/moreindices/index_split_nodes/res_html/index.html
@@ -223,6 +223,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -232,7 +233,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_split_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moreindices/index_split_nodes/res_html/second-chapter.html 
b/tp/t/results/moreindices/index_split_nodes/res_html/second-chapter.html
index 547cfc0..e4ba2ed 100644
--- a/tp/t/results/moreindices/index_split_nodes/res_html/second-chapter.html
+++ b/tp/t/results/moreindices/index_split_nodes/res_html/second-chapter.html
@@ -57,8 +57,8 @@ ul.no-bullet {list-style: none}
 
 <p>Second chapter
 </p>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/index_split_nodes/res_html/section-1.html 
b/tp/t/results/moreindices/index_split_nodes/res_html/section-1.html
index b4127ba..351b801 100644
--- a/tp/t/results/moreindices/index_split_nodes/res_html/section-1.html
+++ b/tp/t/results/moreindices/index_split_nodes/res_html/section-1.html
@@ -134,6 +134,7 @@ ul.no-bullet {list-style: none}
 
 <span id="index-another"></span>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="first.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -150,7 +151,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_split_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/index_split_nodes/res_html/section-2.html 
b/tp/t/results/moreindices/index_split_nodes/res_html/section-2.html
index 0fe0c30..5c3c334 100644
--- a/tp/t/results/moreindices/index_split_nodes/res_html/section-2.html
+++ b/tp/t/results/moreindices/index_split_nodes/res_html/section-2.html
@@ -57,8 +57,8 @@ ul.no-bullet {list-style: none}
 
 <p>Section 2
 </p>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/index_split_nodes/res_html/section-3.html 
b/tp/t/results/moreindices/index_split_nodes/res_html/section-3.html
index 21f950d..4487eac 100644
--- a/tp/t/results/moreindices/index_split_nodes/res_html/section-3.html
+++ b/tp/t/results/moreindices/index_split_nodes/res_html/section-3.html
@@ -124,6 +124,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="first.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -140,7 +141,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_split_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moreindices/index_split_nodes/res_html/subsection-1.html 
b/tp/t/results/moreindices/index_split_nodes/res_html/subsection-1.html
index 293dce4..24ca96c 100644
--- a/tp/t/results/moreindices/index_split_nodes/res_html/subsection-1.html
+++ b/tp/t/results/moreindices/index_split_nodes/res_html/subsection-1.html
@@ -57,8 +57,8 @@ ul.no-bullet {list-style: none}
 
 <p>In subsection 1
 </p>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moreindices/index_split_nodes/res_html/subsection-2.html 
b/tp/t/results/moreindices/index_split_nodes/res_html/subsection-2.html
index 9424bad..47ac668 100644
--- a/tp/t/results/moreindices/index_split_nodes/res_html/subsection-2.html
+++ b/tp/t/results/moreindices/index_split_nodes/res_html/subsection-2.html
@@ -128,6 +128,7 @@ ul.no-bullet {list-style: none}
 
 <span id="index-printindex-subsection-2"></span>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="first.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -144,7 +145,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_split_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/split_chapter_index/res_html/first.html 
b/tp/t/results/moreindices/split_chapter_index/res_html/first.html
index cd2ca23..fe8169a 100644
--- a/tp/t/results/moreindices/split_chapter_index/res_html/first.html
+++ b/tp/t/results/moreindices/split_chapter_index/res_html/first.html
@@ -170,6 +170,9 @@ ul.no-bullet {list-style: none}
 </p>
 <span id="index-printindex-subsection-2"></span>
 
+</div>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#first" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -184,9 +187,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="#first" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="split_chapter_index_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moreindices/split_chapter_index/res_html/index.html 
b/tp/t/results/moreindices/split_chapter_index/res_html/index.html
index 61139ab..5d2a4a9 100644
--- a/tp/t/results/moreindices/split_chapter_index/res_html/index.html
+++ b/tp/t/results/moreindices/split_chapter_index/res_html/index.html
@@ -57,6 +57,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -66,7 +67,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="first.html#first" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="split_chapter_index_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moresectioning/more_sections_than_nodes/res_html/more_sections_than_nodes.html
 
b/tp/t/results/moresectioning/more_sections_than_nodes/res_html/more_sections_than_nodes.html
index c95a67d..1069fdb 100644
--- 
a/tp/t/results/moresectioning/more_sections_than_nodes/res_html/more_sections_than_nodes.html
+++ 
b/tp/t/results/moresectioning/more_sections_than_nodes/res_html/more_sections_than_nodes.html
@@ -58,7 +58,8 @@ ul.no-bullet {list-style: none}
 </table>
 
 <hr size="6">
-<span id="c1"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+<div class="chapter" id="c1">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#Top" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Up section"> Up 
</a>]</td>
@@ -76,6 +77,7 @@ ul.no-bullet {list-style: none}
 <h1 class="chapter">1 c1</h1>
 
 <hr>
+</div>
 <div class="chapter" id="n-c2">
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#c1" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -95,7 +97,8 @@ ul.no-bullet {list-style: none}
 <span id="c2"></span><h1 class="chapter">2 c2</h1>
 
 <hr>
-<span id="s1"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+<div class="section" id="s1">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#n-c2" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#n-c2" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#n-c2" title="Up section"> Up 
</a>]</td>
@@ -114,6 +117,7 @@ ul.no-bullet {list-style: none}
 
 <hr>
 </div>
+</div>
 <div class="chapter" id="n-c3">
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#n-c2" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -138,7 +142,8 @@ ul.no-bullet {list-style: none}
 </table>
 
 <hr>
-<span id="C3-s1"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+<div class="section" id="C3-s1">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#n-c3" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#n-c3" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#n-c3" title="Up section"> Up 
</a>]</td>
@@ -156,6 +161,7 @@ ul.no-bullet {list-style: none}
 <h2 class="section">3.1 C3 s1</h2>
 
 <hr>
+</div>
 <div class="section" id="n-c3-s-2">
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#n-c3" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -175,7 +181,9 @@ ul.no-bullet {list-style: none}
 <span id="c3-s2"></span><h2 class="section">3.2 c3 s2</h2>
 
 <hr>
-<span id="c3-s3"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+</div>
+<div class="section" id="c3-s3">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#n-c3" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#n-c3-s-2" title="Previous section 
in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#n-c3" title="Up section"> Up 
</a>]</td>
@@ -193,7 +201,10 @@ ul.no-bullet {list-style: none}
 <h2 class="section">3.3 c3 s3</h2>
 
 <hr>
-<span id="c4"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+</div>
+</div>
+<div class="chapter" id="c4">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#n-c3" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#c3-s3" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Up section"> Up 
</a>]</td>
@@ -211,7 +222,8 @@ ul.no-bullet {list-style: none}
 <h1 class="chapter">4 c4</h1>
 
 <hr>
-<span id="c3-s1"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+<div class="section" id="c3-s1">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#c4" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#c4" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#c4" title="Up section"> Up 
</a>]</td>
@@ -229,7 +241,8 @@ ul.no-bullet {list-style: none}
 <h2 class="section">4.1 c3 s1</h2>
 
 <hr>
-<span id="c3-s1-s1"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="subsection" id="c3-s1-s1">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#c4" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#c3-s1" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#c3-s1" title="Up section"> Up 
</a>]</td>
@@ -247,6 +260,7 @@ ul.no-bullet {list-style: none}
 <h3 class="subsection">4.1.1 c3 s1 s1</h3>
 
 <hr>
+</div>
 <div class="subsection" id="n-c3-s1-s2">
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#c4" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -266,7 +280,11 @@ ul.no-bullet {list-style: none}
 <span id="c3-s1-s2"></span><h3 class="subsection">4.1.2 c3 s1 s2</h3>
 
 <hr>
-<span id="appendix"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+</div>
+</div>
+</div>
+<div class="appendix" id="appendix">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#c4" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#n-c3-s1-s2" title="Previous 
section in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Up section"> Up 
</a>]</td>
@@ -286,8 +304,6 @@ ul.no-bullet {list-style: none}
 <hr size="6">
 </div>
 </div>
-</div>
-</div>
 <div class="About_element" id="SEC_About">
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#Top" title="Cover (top) of 
document">Top</a>]</td>
diff --git 
a/tp/t/results/moresectioning/node_footnote_use_node/res_html/chapter.html 
b/tp/t/results/moresectioning/node_footnote_use_node/res_html/chapter.html
index ae219b0..d54c020 100644
--- a/tp/t/results/moresectioning/node_footnote_use_node/res_html/chapter.html
+++ b/tp/t/results/moresectioning/node_footnote_use_node/res_html/chapter.html
@@ -60,8 +60,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moresectioning/nodes_after_top_before_chapter_use_nodes_chapter/res_html/third-node.html
 
b/tp/t/results/moresectioning/nodes_after_top_before_chapter_use_nodes_chapter/res_html/third-node.html
index 37cc204..b6bbadf 100644
--- 
a/tp/t/results/moresectioning/nodes_after_top_before_chapter_use_nodes_chapter/res_html/third-node.html
+++ 
b/tp/t/results/moresectioning/nodes_after_top_before_chapter_use_nodes_chapter/res_html/third-node.html
@@ -55,6 +55,7 @@ ul.no-bullet {list-style: none}
 <span id="chapter"></span><h1 class="chapter">1 chapter</h1>
 
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt;&lt; ]</td>
@@ -69,7 +70,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a 
href="nodes_after_top_before_chapter_abt.html#SEC_About" title="About (help)"> 
? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moresectioning/nodes_after_top_before_section_use_nodes_chapter/res_html/index.html
 
b/tp/t/results/moresectioning/nodes_after_top_before_section_use_nodes_chapter/res_html/index.html
index 3df2874..7e0b091 100644
--- 
a/tp/t/results/moresectioning/nodes_after_top_before_section_use_nodes_chapter/res_html/index.html
+++ 
b/tp/t/results/moresectioning/nodes_after_top_before_section_use_nodes_chapter/res_html/index.html
@@ -95,6 +95,7 @@ ul.no-bullet {list-style: none}
 <span id="subsection"></span><h3 class="subsection">1 subsection</h3>
 
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt;&lt; ]</td>
@@ -109,7 +110,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a 
href="nodes_after_top_before_section_abt.html#SEC_About" title="About (help)"> 
? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moresectioning/placed_things_before_element/res_html/placed_things_before_element.html
 
b/tp/t/results/moresectioning/placed_things_before_element/res_html/placed_things_before_element.html
index f6a71bf..b12ae6e 100644
--- 
a/tp/t/results/moresectioning/placed_things_before_element/res_html/placed_things_before_element.html
+++ 
b/tp/t/results/moresectioning/placed_things_before_element/res_html/placed_things_before_element.html
@@ -63,7 +63,8 @@ ul.no-bullet {list-style: none}
 
 <span id="index-index-entry"></span>
 
-<span id="section"></span><h2 class="section">1 section</h2>
+<div class="section" id="section">
+<h2 class="section">1 section</h2>
 
 <p>Ref to anchor
 <a href="#An-anchor">An anchor</a>
@@ -83,7 +84,8 @@ ul.no-bullet {list-style: none}
 <a href="#An-anchor">An anchor</a>
 </p>
 </div>
-<hr><p><font size="-1">
+<hr></div>
+<p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
 
diff --git 
a/tp/t/results/moresectioning/sectioning_frames/res_html/First-node.html 
b/tp/t/results/moresectioning/sectioning_frames/res_html/First-node.html
index 7d835e6..614a9e5 100644
--- a/tp/t/results/moresectioning/sectioning_frames/res_html/First-node.html
+++ b/tp/t/results/moresectioning/sectioning_frames/res_html/First-node.html
@@ -245,6 +245,8 @@ ul.no-bullet {list-style: none}
 <span id="between-node"></span>
 <p>between node, node without sectioning node
 </p>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#First-node" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -259,8 +261,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="sectioning_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moresectioning/sectioning_frames/res_html/Second-node.html 
b/tp/t/results/moresectioning/sectioning_frames/res_html/Second-node.html
index 210e4bc..991f949 100644
--- a/tp/t/results/moresectioning/sectioning_frames/res_html/Second-node.html
+++ b/tp/t/results/moresectioning/sectioning_frames/res_html/Second-node.html
@@ -59,6 +59,7 @@ ul.no-bullet {list-style: none}
 
 <p>second node chapter text.
 </p>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="First-node.html#First-node" 
title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -73,7 +74,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="sectioning_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/t/results/moresectioning/sectioning_frames/res_html/Third-node-unnumbered.html
 
b/tp/t/results/moresectioning/sectioning_frames/res_html/Third-node-unnumbered.html
index ea2e788..dbc8d85 100644
--- 
a/tp/t/results/moresectioning/sectioning_frames/res_html/Third-node-unnumbered.html
+++ 
b/tp/t/results/moresectioning/sectioning_frames/res_html/Third-node-unnumbered.html
@@ -58,6 +58,7 @@ ul.no-bullet {list-style: none}
 </p>
 
 <span id="Last-node-no-description"></span>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Second-node.html" 
title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -72,7 +73,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="sectioning_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/moresectioning/sectioning_frames/res_html/index.html 
b/tp/t/results/moresectioning/sectioning_frames/res_html/index.html
index 1b705e2..5b3c148 100644
--- a/tp/t/results/moresectioning/sectioning_frames/res_html/index.html
+++ b/tp/t/results/moresectioning/sectioning_frames/res_html/index.html
@@ -78,6 +78,7 @@ description here
 
 </pre></th></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -87,7 +88,6 @@ description here
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="sectioning_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/t/results/regions/anchor_in_titlepage.pl 
b/tp/t/results/regions/anchor_in_titlepage.pl
index fa91447..47de7a2 100644
--- a/tp/t/results/regions/anchor_in_titlepage.pl
+++ b/tp/t/results/regions/anchor_in_titlepage.pl
@@ -390,11 +390,13 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 
-<span id="top"></span><h1 class="top">top</h1>
+<div class="top" id="top">
+<h1 class="top">top</h1>
 <span id="Top"></span><h1 class="node-heading">Top</h1>
 
 <p>See <a href="#in-titlepage">in titlepage</a>.
-</p><hr>
+</p><hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/regions/anchor_in_titlepage_titlepage.pl 
b/tp/t/results/regions/anchor_in_titlepage_titlepage.pl
index 14a17b3..afaba47 100644
--- a/tp/t/results/regions/anchor_in_titlepage_titlepage.pl
+++ b/tp/t/results/regions/anchor_in_titlepage_titlepage.pl
@@ -392,11 +392,13 @@ ul.no-bullet {list-style: none}
 
 <span id="in-titlepage"></span><hr>
 
-<span id="top"></span><h1 class="top">top</h1>
+<div class="top" id="top">
+<h1 class="top">top</h1>
 <span id="Top"></span><h1 class="node-heading">Top</h1>
 
 <p>See <a href="#in-titlepage">in titlepage</a>.
-</p><hr>
+</p><hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/regions/ref_in_copying.pl 
b/tp/t/results/regions/ref_in_copying.pl
index 3b6525b..efeb4c6 100644
--- a/tp/t/results/regions/ref_in_copying.pl
+++ b/tp/t/results/regions/ref_in_copying.pl
@@ -721,9 +721,9 @@ Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, 
Up: <a href="#Top" ac
 </div>
 <span id="GFDL-1"></span><h2 class="chapter">1 GFDL</h2>
 
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/anchor_in_footnote.pl 
b/tp/t/results/sectioning/anchor_in_footnote.pl
index a073e4a..ef81df6 100644
--- a/tp/t/results/sectioning/anchor_in_footnote.pl
+++ b/tp/t/results/sectioning/anchor_in_footnote.pl
@@ -727,7 +727,9 @@ Previous: <a href="#Top" accesskey="p" rel="prev">Top</a>, 
Up: <a href="#Top" ac
 <span id="Chap"></span><h2 class="chapter">1 Chap</h2>
 
 <p><a href="#Anchor-in-footnote">Anchor in footnote</a>.
-</p><div class="footnote">
+</p></div>
+</div>
+<div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
 
@@ -737,8 +739,6 @@ Previous: <a href="#Top" accesskey="p" rel="prev">Top</a>, 
Up: <a href="#Top" ac
 </p>
 </div>
 <hr>
-</div>
-</div>
 
 
 
diff --git a/tp/t/results/sectioning/anchor_in_footnote_separate.pl 
b/tp/t/results/sectioning/anchor_in_footnote_separate.pl
index 39ca841..d4e95c3 100644
--- a/tp/t/results/sectioning/anchor_in_footnote_separate.pl
+++ b/tp/t/results/sectioning/anchor_in_footnote_separate.pl
@@ -765,9 +765,9 @@ Previous: <a href="#Top" accesskey="p" rel="prev">Top</a>, 
Up: <a href="#Top" ac
 <span id="Chap"></span><h2 class="chapter">1 Chap</h2>
 
 <p><a href="#Anchor-in-footnote">Anchor in footnote</a>.
-</p><hr>
-</div>
+</p></div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/chapter_before_and_after_part.pl 
b/tp/t/results/sectioning/chapter_before_and_after_part.pl
index 0964d7b..d9abf89 100644
--- a/tp/t/results/sectioning/chapter_before_and_after_part.pl
+++ b/tp/t/results/sectioning/chapter_before_and_after_part.pl
@@ -373,15 +373,19 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="chapter"></span><h2 class="chapter">1 chapter</h2>
+<div class="chapter" id="chapter">
+<h2 class="chapter">1 chapter</h2>
 
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
 <li><a href="#chapter-2" accesskey="1">chapter 2</a></li>
 </ul>
-<span id="chapter-2"></span><h2 class="chapter">2 chapter 2</h2>
+<div class="chapter" id="chapter-2">
+<h2 class="chapter">2 chapter 2</h2>
 
 <div class="Contents_element" id="SEC_Contents">
 <h2 class="contents-heading">Table of Contents</h2>
@@ -397,7 +401,9 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
-<hr>
+<hr></div>
+</div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/chapter_before_part.pl 
b/tp/t/results/sectioning/chapter_before_part.pl
index 56fc043..b0d9135 100644
--- a/tp/t/results/sectioning/chapter_before_part.pl
+++ b/tp/t/results/sectioning/chapter_before_part.pl
@@ -265,11 +265,15 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="chapter"></span><h2 class="chapter">1 chapter</h2>
+<div class="chapter" id="chapter">
+<h2 class="chapter">1 chapter</h2>
 
-<span id="part"></span><h1 class="part">part</h1>
-<hr>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
+<hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/chapter_between_nodes.pl 
b/tp/t/results/sectioning/chapter_between_nodes.pl
index 6d2ac6d..2acebc8 100644
--- a/tp/t/results/sectioning/chapter_between_nodes.pl
+++ b/tp/t/results/sectioning/chapter_between_nodes.pl
@@ -748,7 +748,8 @@ Next: <a href="#section-node" accesskey="n" 
rel="next">section</a> &nbsp; [<a hr
 <p>Top node
 </p>
 
-<span id="Chapter"></span><h2 class="chapter">1 Chapter</h2>
+<div class="chapter" id="Chapter">
+<h2 class="chapter">1 Chapter</h2>
 
 <p>In chapter
 </p>
@@ -778,9 +779,10 @@ Previous: <a href="#Top" accesskey="p" rel="prev">top 
section</a>, Up: <a href="
 </ul>
 </div>
 </div>
-<hr>
 </div>
 </div>
+</div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/chapter_node_before_and_after_part.pl 
b/tp/t/results/sectioning/chapter_node_before_and_after_part.pl
index 44f35da..c3ef521 100644
--- a/tp/t/results/sectioning/chapter_node_before_and_after_part.pl
+++ b/tp/t/results/sectioning/chapter_node_before_and_after_part.pl
@@ -675,7 +675,9 @@ Next: <a href="#after" accesskey="n" rel="next">chapter 
2</a> &nbsp; [<a href="#
 
 
 <hr>
-<span id="part"></span><div class="header">
+</div>
+<div class="part" id="part">
+<div class="header">
 <p>
 Previous: <a href="#Top" accesskey="p" rel="prev">chapter</a>, Up: <a 
href="#Top" accesskey="u" rel="up">chapter</a> &nbsp; [<a href="#SEC_Contents" 
title="Table of contents" rel="contents">Contents</a>]</p>
 </div>
@@ -685,7 +687,6 @@ Previous: <a href="#Top" accesskey="p" 
rel="prev">chapter</a>, Up: <a href="#Top
 <ul class="section-toc">
 <li><a href="#after" accesskey="1">chapter 2</a></li>
 </ul>
-</div>
 <div class="chapter" id="after">
 <span id="chapter-2"></span><h2 class="chapter">2 chapter 2</h2>
 
@@ -703,8 +704,9 @@ Previous: <a href="#Top" accesskey="p" 
rel="prev">chapter</a>, Up: <a href="#Top
 </ul>
 </div>
 </div>
-<hr>
 </div>
+</div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/character_and_spaces_in_refs.pl 
b/tp/t/results/sectioning/character_and_spaces_in_refs.pl
index bb9e002..6c87621 100644
--- a/tp/t/results/sectioning/character_and_spaces_in_refs.pl
+++ b/tp/t/results/sectioning/character_and_spaces_in_refs.pl
@@ -2066,9 +2066,9 @@ Previous: <a 
href="#g_t_002f_003b_003c_003d_003e_003f_005b_005c_005d_005e_005f_0
 </div>
 <h4 class="node-heading">local   node</h4>
 
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git 
a/tp/t/results/sectioning/character_and_spaces_in_refs_out/res_html/index.html 
b/tp/t/results/sectioning/character_and_spaces_in_refs_out/res_html/index.html
index cb4efcd..ca357d0 100644
--- 
a/tp/t/results/sectioning/character_and_spaces_in_refs_out/res_html/index.html
+++ 
b/tp/t/results/sectioning/character_and_spaces_in_refs_out/res_html/index.html
@@ -64,12 +64,12 @@ Next: <a href="other-nodes.html" accesskey="n" 
rel="next">Chapter with nodes</a>
 <ul class="section-toc">
 <li><a href="other-nodes.html" accesskey="1">Chapter with nodes</a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="other-nodes.html" accesskey="n" rel="next">Chapter with 
nodes</a> &nbsp; </p>
 </div>
-</div>
 
 
 
diff --git a/tp/t/results/sectioning/contents.pl 
b/tp/t/results/sectioning/contents.pl
index 3e028a0..10b112c 100644
--- a/tp/t/results/sectioning/contents.pl
+++ b/tp/t/results/sectioning/contents.pl
@@ -804,7 +804,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><h1 class="top">top</h1>
+<div class="top" id="top">
+<h1 class="top">top</h1>
 
 <div class="Contents_element" id="SEC_Contents">
 <h2 class="contents-heading">Table of Contents</h2>
@@ -838,24 +839,34 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
-<span id="chapter"></span><h2 class="chapter">1 chapter</h2>
+<div class="chapter" id="chapter">
+<h2 class="chapter">1 chapter</h2>
 
 <ul class="section-toc">
 <li><a href="#section" accesskey="1">section</a></li>
 </ul>
-<span id="section"></span><h3 class="section">1.1 section</h3>
+<div class="section" id="section">
+<h3 class="section">1.1 section</h3>
 
 <ul class="section-toc">
 <li><a href="#subsection" accesskey="1">subsection</a></li>
 </ul>
-<span id="subsection"></span><h4 class="subsection">1.1.1 subsection</h4>
+<div class="subsection" id="subsection">
+<h4 class="subsection">1.1.1 subsection</h4>
 
 <ul class="section-toc">
 <li><a href="#subsubsection" accesskey="1">subsubsection</a></li>
 </ul>
-<span id="subsubsection"></span><h4 class="subsubsection">1.1.1.1 
subsubsection</h4>
+<div class="subsubsection" id="subsubsection">
+<h4 class="subsubsection">1.1.1.1 subsubsection</h4>
 
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+</div>
+</div>
+</div>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
@@ -863,20 +874,31 @@ ul.no-bullet {list-style: none}
 <li><a href="#second-chapter-in-part" accesskey="2">second chapter in 
part</a></li>
 <li><a href="#unnumbered" accesskey="3">unnumbered</a></li>
 </ul>
-<span id="chapter-in-part"></span><h2 class="chapter">2 chapter in part</h2>
+<div class="chapter" id="chapter-in-part">
+<h2 class="chapter">2 chapter in part</h2>
 
-<span id="second-chapter-in-part"></span><h2 class="chapter">3 second chapter 
in part</h2>
+</div>
+<div class="chapter" id="second-chapter-in-part">
+<h2 class="chapter">3 second chapter in part</h2>
 
-<span id="unnumbered"></span><h2 class="unnumbered">unnumbered</h2>
+</div>
+<div class="unnumbered" id="unnumbered">
+<h2 class="unnumbered">unnumbered</h2>
 
-<span id="appendix"></span><h2 class="appendix">Appendix A appendix</h2>
+</div>
+<div class="appendix" id="appendix">
+<h2 class="appendix">Appendix A appendix</h2>
 
 <ul class="section-toc">
 <li><a href="#appendixsec" accesskey="1">appendixsec</a></li>
 </ul>
-<span id="appendixsec"></span><h3 class="appendixsec">A.1 appendixsec</h3>
+<div class="appendixsec" id="appendixsec">
+<h3 class="appendixsec">A.1 appendixsec</h3>
+
+<hr></div>
+</div>
+</div>
 
-<hr>
 
 
 </body>
diff --git a/tp/t/results/sectioning/contents_and_shortcontents.pl 
b/tp/t/results/sectioning/contents_and_shortcontents.pl
index 440f258..6e8ccf1 100644
--- a/tp/t/results/sectioning/contents_and_shortcontents.pl
+++ b/tp/t/results/sectioning/contents_and_shortcontents.pl
@@ -840,7 +840,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><h1 class="top">top</h1>
+<div class="top" id="top">
+<h1 class="top">top</h1>
 
 <div class="Contents_element" id="SEC_Contents">
 <h2 class="contents-heading">Table of Contents</h2>
@@ -892,24 +893,34 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
-<span id="chapter"></span><h2 class="chapter">1 chapter</h2>
+<div class="chapter" id="chapter">
+<h2 class="chapter">1 chapter</h2>
 
 <ul class="section-toc">
 <li><a href="#section" accesskey="1">section</a></li>
 </ul>
-<span id="section"></span><h3 class="section">1.1 section</h3>
+<div class="section" id="section">
+<h3 class="section">1.1 section</h3>
 
 <ul class="section-toc">
 <li><a href="#subsection" accesskey="1">subsection</a></li>
 </ul>
-<span id="subsection"></span><h4 class="subsection">1.1.1 subsection</h4>
+<div class="subsection" id="subsection">
+<h4 class="subsection">1.1.1 subsection</h4>
 
 <ul class="section-toc">
 <li><a href="#subsubsection" accesskey="1">subsubsection</a></li>
 </ul>
-<span id="subsubsection"></span><h4 class="subsubsection">1.1.1.1 
subsubsection</h4>
+<div class="subsubsection" id="subsubsection">
+<h4 class="subsubsection">1.1.1.1 subsubsection</h4>
 
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+</div>
+</div>
+</div>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
@@ -917,21 +928,32 @@ ul.no-bullet {list-style: none}
 <li><a href="#second-chapter-in-part" accesskey="2">second chapter in 
part</a></li>
 <li><a href="#unnumbered" accesskey="3">unnumbered</a></li>
 </ul>
-<span id="chapter-in-part"></span><h2 class="chapter">2 chapter in part</h2>
+<div class="chapter" id="chapter-in-part">
+<h2 class="chapter">2 chapter in part</h2>
 
-<span id="second-chapter-in-part"></span><h2 class="chapter">3 second chapter 
in part</h2>
+</div>
+<div class="chapter" id="second-chapter-in-part">
+<h2 class="chapter">3 second chapter in part</h2>
 
-<span id="unnumbered"></span><h2 class="unnumbered">unnumbered</h2>
+</div>
+<div class="unnumbered" id="unnumbered">
+<h2 class="unnumbered">unnumbered</h2>
 
-<span id="appendix"></span><h2 class="appendix">Appendix A appendix</h2>
+</div>
+<div class="appendix" id="appendix">
+<h2 class="appendix">Appendix A appendix</h2>
 
 <ul class="section-toc">
 <li><a href="#appendixsec" accesskey="1">appendixsec</a></li>
 </ul>
-<span id="appendixsec"></span><h3 class="appendixsec">A.1 appendixsec</h3>
+<div class="appendixsec" id="appendixsec">
+<h3 class="appendixsec">A.1 appendixsec</h3>
 
 
-<hr>
+<hr></div>
+</div>
+</div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/contents_in_html_text.pl 
b/tp/t/results/sectioning/contents_in_html_text.pl
index 2f51251..074024f 100644
--- a/tp/t/results/sectioning/contents_in_html_text.pl
+++ b/tp/t/results/sectioning/contents_in_html_text.pl
@@ -315,16 +315,22 @@ $result_floats{'contents_in_html_text'} = {};
 
 
 
-$result_converted{'html_text'}->{'contents_in_html_text'} = '<span 
id="top"></span><h1 class="top">top</h1>
+$result_converted{'html_text'}->{'contents_in_html_text'} = '<div class="top" 
id="top">
+<h1 class="top">top</h1>
 
-<span id="Chap1"></span><h2 class="chapter">1 Chap1</h2>
+<div class="chapter" id="Chap1">
+<h2 class="chapter">1 Chap1</h2>
 
 <ul class="section-toc">
 <li><a href="#Sec-1" accesskey="1">Sec 1</a></li>
 </ul>
-<span id="Sec-1"></span><h3 class="section">1.1 Sec 1</h3>
+<div class="section" id="Sec-1">
+<h3 class="section">1.1 Sec 1</h3>
 
-<span id="Chap2"></span><h2 class="chapter">2 Chap2</h2>
+</div>
+</div>
+<div class="chapter" id="Chap2">
+<h2 class="chapter">2 Chap2</h2>
 
 <div class="Overview_element">
 <h2 class="shortcontents-heading">Short Table of Contents</h2>
@@ -350,6 +356,8 @@ $result_converted{'html_text'}->{'contents_in_html_text'} = 
'<span id="top"></sp
 </ul>
 </div>
 </div>
-<hr>';
+<hr></div>
+</div>
+';
 
 1;
diff --git a/tp/t/results/sectioning/double_part.pl 
b/tp/t/results/sectioning/double_part.pl
index c893553..6b857d1 100644
--- a/tp/t/results/sectioning/double_part.pl
+++ b/tp/t/results/sectioning/double_part.pl
@@ -906,12 +906,16 @@ Next: <a href="#node-chapter" accesskey="n" 
rel="next">chapter after 2 parts</a>
 <span id="top"></span><h1 class="top">top</h1>
 
 
-<span id="part-first"></span><h1 class="part">part first</h1>
+</div>
+<div class="part" id="part-first">
+<h1 class="part">part first</h1>
 <hr>
 
 <p>Text part first.
 </p><hr>
-<span id="part-second"></span><div class="header">
+</div>
+<div class="part" id="part-second">
+<div class="header">
 <p>
 Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -925,9 +929,9 @@ Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, 
Up: <a href="#Top" ac
 <div class="chapter" id="node-chapter">
 <span id="chapter-after-2-parts"></span><h2 class="chapter">1 chapter after 2 
parts</h2>
 
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/empty_top_node_up.pl 
b/tp/t/results/sectioning/empty_top_node_up.pl
index 15064ad..a4a126d 100644
--- a/tp/t/results/sectioning/empty_top_node_up.pl
+++ b/tp/t/results/sectioning/empty_top_node_up.pl
@@ -476,8 +476,8 @@ Next: <a href="#first" accesskey="n" rel="next">first</a> 
&nbsp; </p>
 Previous: <a href="#Top" accesskey="p" rel="prev">empty top node up</a>, Up: 
<a href="#Top" accesskey="u" rel="up">empty top node up</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">first</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/external_node_in_menu.pl 
b/tp/t/results/sectioning/external_node_in_menu.pl
index e6805dd..26cb68e 100644
--- a/tp/t/results/sectioning/external_node_in_menu.pl
+++ b/tp/t/results/sectioning/external_node_in_menu.pl
@@ -873,9 +873,9 @@ Next: <a href="#nchapter2" accesskey="n" 
rel="next">chap2</a>, Previous: <a href
 Previous: <a href="#nchapter1" accesskey="p" rel="prev">chap1</a>, Up: <a 
href="#Top" accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
 <span id="chap2"></span><h2 class="chapter">2 chap2</h2>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/internal_top_node_up.pl 
b/tp/t/results/sectioning/internal_top_node_up.pl
index 1716503..3d08f9d 100644
--- a/tp/t/results/sectioning/internal_top_node_up.pl
+++ b/tp/t/results/sectioning/internal_top_node_up.pl
@@ -584,8 +584,8 @@ Next: <a href="#first" accesskey="n" rel="next">first</a> 
&nbsp; </p>
 Previous: <a href="#Top" accesskey="p" rel="prev">internal top node up</a>, 
Up: <a href="#Top" accesskey="u" rel="up">internal top node up</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">first</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/next_in_menu_is_below.pl 
b/tp/t/results/sectioning/next_in_menu_is_below.pl
index bef7c2f..1139f29 100644
--- a/tp/t/results/sectioning/next_in_menu_is_below.pl
+++ b/tp/t/results/sectioning/next_in_menu_is_below.pl
@@ -1289,11 +1289,11 @@ Next: <a href="#subsection" accesskey="n" 
rel="next">subsection</a>, Up: <a href
 Previous: <a href="#section" accesskey="p" rel="prev">section</a>, Up: <a 
href="#section" accesskey="u" rel="up">section</a> &nbsp; </p>
 </div>
 <span id="subsection-1"></span><h4 class="subsection">1.1.1 subsection</h4>
-<hr>
 </div>
 </div>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/no_argument_and_contents.pl 
b/tp/t/results/sectioning/no_argument_and_contents.pl
index 459c912..8b387f3 100644
--- a/tp/t/results/sectioning/no_argument_and_contents.pl
+++ b/tp/t/results/sectioning/no_argument_and_contents.pl
@@ -247,7 +247,8 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 
-<span id="for-example"></span><h1 class="top">for example</h1>
+<div class="top" id="for-example">
+<h1 class="top">for example</h1>
 
 <div class="Contents_element" id="SEC_Contents">
 <h2 class="contents-heading">Table of Contents</h2>
@@ -259,9 +260,12 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
+<div class="chapter">
 <h2 class="chapter">1 </h2>
 
-<hr>
+<hr></div>
+</div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/no_menu.pl 
b/tp/t/results/sectioning/no_menu.pl
index d5b1091..05df313 100644
--- a/tp/t/results/sectioning/no_menu.pl
+++ b/tp/t/results/sectioning/no_menu.pl
@@ -615,9 +615,9 @@ Next: <a href="#c3" accesskey="n" rel="next">c3</a>, 
Previous: <a href="#c1" acc
 Previous: <a href="#c2" accesskey="p" rel="prev">c2</a> &nbsp; </p>
 </div>
 <span id="c3-1"></span><h2 class="chapter">3 c3</h2>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/node_part_chapter_after_chapter.pl 
b/tp/t/results/sectioning/node_part_chapter_after_chapter.pl
index 3d7f9a6..80e7601 100644
--- a/tp/t/results/sectioning/node_part_chapter_after_chapter.pl
+++ b/tp/t/results/sectioning/node_part_chapter_after_chapter.pl
@@ -1151,7 +1151,10 @@ Next: <a href="#part-chapter-node" accesskey="n" 
rel="next">chapter with part no
 <p>
 Previous: <a href="#chapter-node" accesskey="p" rel="prev">chapter node</a>, 
Up: <a href="#Top" accesskey="u" rel="up">top</a> &nbsp; [<a 
href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
 </div>
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
@@ -1159,9 +1162,8 @@ Previous: <a href="#chapter-node" accesskey="p" 
rel="prev">chapter node</a>, Up:
 </ul>
 <span id="chapter-with-part-node"></span><h2 class="chapter">2 chapter with 
part node</h2>
 
-<hr>
-</div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/node_part_chapter_after_top.pl 
b/tp/t/results/sectioning/node_part_chapter_after_top.pl
index e20c4a0..fd9385a 100644
--- a/tp/t/results/sectioning/node_part_chapter_after_top.pl
+++ b/tp/t/results/sectioning/node_part_chapter_after_top.pl
@@ -758,16 +758,18 @@ Next: <a href="#chapter-node" accesskey="n" 
rel="next">chapter</a> &nbsp; </p>
 <p>
 Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
 <li><a href="#chapter-node" accesskey="1">chapter</a></li>
 </ul>
 <span id="chapter"></span><h2 class="chapter">1 chapter</h2>
-<hr>
-</div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/nodes_after_top_before_chapter_nodes.pl 
b/tp/t/results/sectioning/nodes_after_top_before_chapter_nodes.pl
index 05ee70e..78125c7 100644
--- a/tp/t/results/sectioning/nodes_after_top_before_chapter_nodes.pl
+++ b/tp/t/results/sectioning/nodes_after_top_before_chapter_nodes.pl
@@ -951,8 +951,8 @@ Next: <a href="#third-node" accesskey="n" 
rel="next">chapter</a>, Previous: <a h
 Previous: <a href="#second-node" accesskey="p" rel="prev">second node</a>, Up: 
<a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; </p>
 </div>
 <span id="chapter"></span><h2 class="chapter">1 chapter</h2>
-<hr>
 </div>
+<hr>
 
 
 
diff --git 
a/tp/t/results/sectioning/nodes_after_top_before_chapter_not_split.pl 
b/tp/t/results/sectioning/nodes_after_top_before_chapter_not_split.pl
index 0c74ed3..90ef67a 100644
--- a/tp/t/results/sectioning/nodes_after_top_before_chapter_not_split.pl
+++ b/tp/t/results/sectioning/nodes_after_top_before_chapter_not_split.pl
@@ -754,8 +754,8 @@ Next: <a href="#third-node" accesskey="n" 
rel="next">chapter</a>, Previous: <a h
 Previous: <a href="#second-node" accesskey="p" rel="prev">second node</a>, Up: 
<a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; </p>
 </div>
 <span id="chapter"></span><h2 class="chapter">1 chapter</h2>
-<hr>
 </div>
+<hr>
 
 
 
diff --git 
a/tp/t/results/sectioning/nodes_after_top_before_chapter_not_split_no_use_node_directions.pl
 
b/tp/t/results/sectioning/nodes_after_top_before_chapter_not_split_no_use_node_directions.pl
index e154cb6..4d30032 100644
--- 
a/tp/t/results/sectioning/nodes_after_top_before_chapter_not_split_no_use_node_directions.pl
+++ 
b/tp/t/results/sectioning/nodes_after_top_before_chapter_not_split_no_use_node_directions.pl
@@ -754,8 +754,8 @@ ul.no-bullet {list-style: none}
  &nbsp; </p>
 </div>
 <span id="chapter"></span><h2 class="chapter">1 chapter</h2>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/nodes_after_top_before_chapter_sections.pl 
b/tp/t/results/sectioning/nodes_after_top_before_chapter_sections.pl
index 5af00a5..cdb37c5 100644
--- a/tp/t/results/sectioning/nodes_after_top_before_chapter_sections.pl
+++ b/tp/t/results/sectioning/nodes_after_top_before_chapter_sections.pl
@@ -859,8 +859,8 @@ Next: <a href="#third-node" accesskey="n" 
rel="next">chapter</a>, Previous: <a h
 Previous: <a href="#second-node" accesskey="p" rel="prev">second node</a>, Up: 
<a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; </p>
 </div>
 <span id="chapter"></span><h2 class="chapter">1 chapter</h2>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/nodes_after_top_before_section_nodes.pl 
b/tp/t/results/sectioning/nodes_after_top_before_section_nodes.pl
index a3bfebf..bc5afcb 100644
--- a/tp/t/results/sectioning/nodes_after_top_before_section_nodes.pl
+++ b/tp/t/results/sectioning/nodes_after_top_before_section_nodes.pl
@@ -953,8 +953,8 @@ Next: <a href="#third-node" accesskey="n" 
rel="next">subsection</a>, Previous: <
 Previous: <a href="#second-node" accesskey="p" rel="prev">second node</a>, Up: 
<a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; </p>
 </div>
 <span id="subsection"></span><h4 class="subsection">1 subsection</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/nodes_after_top_before_section_sections.pl 
b/tp/t/results/sectioning/nodes_after_top_before_section_sections.pl
index 93b34cd..4d382df 100644
--- a/tp/t/results/sectioning/nodes_after_top_before_section_sections.pl
+++ b/tp/t/results/sectioning/nodes_after_top_before_section_sections.pl
@@ -861,8 +861,8 @@ Next: <a href="#third-node" accesskey="n" 
rel="next">subsection</a>, Previous: <
 Previous: <a href="#second-node" accesskey="p" rel="prev">second node</a>, Up: 
<a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; </p>
 </div>
 <span id="subsection"></span><h4 class="subsection">1 subsection</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/non_automatic_internal_top_node_up.pl 
b/tp/t/results/sectioning/non_automatic_internal_top_node_up.pl
index 99e9ff1..152b4bd 100644
--- a/tp/t/results/sectioning/non_automatic_internal_top_node_up.pl
+++ b/tp/t/results/sectioning/non_automatic_internal_top_node_up.pl
@@ -935,8 +935,8 @@ Next: <a href="#first" accesskey="n" rel="next">first</a> 
&nbsp; </p>
 Previous: <a href="#Top" accesskey="p" rel="prev">internal top node up</a> 
&nbsp; </p>
 </div>
 <h4 class="node-heading">first</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/non_automatic_top_node_up_and_url.pl 
b/tp/t/results/sectioning/non_automatic_top_node_up_and_url.pl
index 6438131..f2d4278 100644
--- a/tp/t/results/sectioning/non_automatic_top_node_up_and_url.pl
+++ b/tp/t/results/sectioning/non_automatic_top_node_up_and_url.pl
@@ -936,8 +936,8 @@ Next: <a href="#first" accesskey="n" rel="next">first</a>, 
Up: <a href="http://w
 Previous: <a href="#Top" accesskey="p" rel="prev">internal top node up</a> 
&nbsp; </p>
 </div>
 <h4 class="node-heading">first</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/non_automatic_top_node_up_url.pl 
b/tp/t/results/sectioning/non_automatic_top_node_up_url.pl
index d2886e7..b6669ae 100644
--- a/tp/t/results/sectioning/non_automatic_top_node_up_url.pl
+++ b/tp/t/results/sectioning/non_automatic_top_node_up_url.pl
@@ -783,8 +783,8 @@ Next: <a href="#first" accesskey="n" rel="next">first</a>, 
Previous: <a href="di
 Previous: <a href="#Top" accesskey="p" rel="prev">internal top node up</a>, 
Up: <a href="dir.html#Top" accesskey="u" rel="up">(dir)</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">first</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/one_subsection.pl 
b/tp/t/results/sectioning/one_subsection.pl
index 0908e79..f004907 100644
--- a/tp/t/results/sectioning/one_subsection.pl
+++ b/tp/t/results/sectioning/one_subsection.pl
@@ -125,8 +125,10 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="The-subsection"></span><h4 class="subsection">1 The subsection</h4>
-<hr>
+<div class="subsection" id="The-subsection">
+<h4 class="subsection">1 The subsection</h4>
+<hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/part_before_chapter.pl 
b/tp/t/results/sectioning/part_before_chapter.pl
index b0ca3a2..43c5312 100644
--- a/tp/t/results/sectioning/part_before_chapter.pl
+++ b/tp/t/results/sectioning/part_before_chapter.pl
@@ -231,14 +231,18 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="part"></span><h1 class="part">part</h1>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
 <li><a href="#chapter" accesskey="1">chapter</a></li>
 </ul>
-<span id="chapter"></span><h2 class="chapter">1 chapter</h2>
-<hr>
+<div class="chapter" id="chapter">
+<h2 class="chapter">1 chapter</h2>
+<hr></div>
+</div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/part_before_section.pl 
b/tp/t/results/sectioning/part_before_section.pl
index 895784f..b9804da 100644
--- a/tp/t/results/sectioning/part_before_section.pl
+++ b/tp/t/results/sectioning/part_before_section.pl
@@ -198,14 +198,18 @@ $result_directions_text{'part_before_section'} = 
'element: @section section
 ';
 
 
-$result_converted{'html_text'}->{'part_before_section'} = '<span 
id="part"></span><h1 class="part">part</h1>
+$result_converted{'html_text'}->{'part_before_section'} = '<div class="part" 
id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
 <li><a href="#section" accesskey="1">section</a></li>
 </ul>
-<span id="section"></span><h2 class="chapter">1 section</h2>
-<hr>';
+<div class="section" id="section">
+<h2 class="chapter">1 section</h2>
+<hr></div>
+</div>
+';
 
 
 $result_converted{'xml'}->{'part_before_section'} = '<part spaces=" 
"><sectiontitle>part</sectiontitle>
diff --git a/tp/t/results/sectioning/part_before_top.pl 
b/tp/t/results/sectioning/part_before_top.pl
index 1604c90..43b170b 100644
--- a/tp/t/results/sectioning/part_before_top.pl
+++ b/tp/t/results/sectioning/part_before_top.pl
@@ -238,11 +238,15 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="part"></span><h1 class="part">part</h1>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
-<span id="top"></span><h1 class="top">top</h1>
-<hr>
+</div>
+<div class="top" id="top">
+<h1 class="top">top</h1>
+<hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/part_chapter_after_top.pl 
b/tp/t/results/sectioning/part_chapter_after_top.pl
index fd6db0d..451ebec 100644
--- a/tp/t/results/sectioning/part_chapter_after_top.pl
+++ b/tp/t/results/sectioning/part_chapter_after_top.pl
@@ -743,7 +743,9 @@ Next: <a href="#chapter" accesskey="n" 
rel="next">chapter</a> &nbsp; </p>
 
 
 <hr>
-<span id="part"></span><div class="header">
+</div>
+<div class="part" id="part">
+<div class="header">
 <p>
 Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -755,9 +757,9 @@ Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, 
Up: <a href="#Top" ac
 </ul>
 <div class="chapter" id="chapter">
 <span id="chapter-1"></span><h2 class="chapter">1 chapter</h2>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/part_node_after_top.pl 
b/tp/t/results/sectioning/part_node_after_top.pl
index 7896551..4a250a4 100644
--- a/tp/t/results/sectioning/part_node_after_top.pl
+++ b/tp/t/results/sectioning/part_node_after_top.pl
@@ -658,10 +658,12 @@ Next: <a href="#part-node-after-top" accesskey="n" 
rel="next">part node after to
 Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">part node after top</h4>
-<span id="part"></span><h1 class="part">part</h1>
-<hr>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/part_node_before_top.pl 
b/tp/t/results/sectioning/part_node_before_top.pl
index 4e79bde..f6b22c0 100644
--- a/tp/t/results/sectioning/part_node_before_top.pl
+++ b/tp/t/results/sectioning/part_node_before_top.pl
@@ -669,18 +669,20 @@ Next: <a href="#Top" accesskey="n" rel="next">top</a>, 
Previous: <a href="#Top"
 </div>
 <h4 class="node-heading">part node before top</h4>
 <hr>
-<span id="part"></span><div class="header">
+<div class="part" id="part">
+<div class="header">
 <p>
 Next: <a href="#part-node-before-top" accesskey="n" rel="next">part node 
before top</a> &nbsp; </p>
 </div>
 <h1 class="part">part</h1>
 <hr>
 
+</div>
 <div class="top" id="Top">
 <span id="top"></span><h1 class="top">top</h1>
 
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/part_node_chapter_after_top.pl 
b/tp/t/results/sectioning/part_node_chapter_after_top.pl
index d8ad8ac..6f11316 100644
--- a/tp/t/results/sectioning/part_node_chapter_after_top.pl
+++ b/tp/t/results/sectioning/part_node_chapter_after_top.pl
@@ -1046,7 +1046,9 @@ Next: <a href="#a-node-after-part" accesskey="n" 
rel="next">a node after part</a
 
 
 <hr>
-<span id="part"></span><div class="header">
+</div>
+<div class="part" id="part">
+<div class="header">
 <p>
 Next: <a href="#chapter" accesskey="n" rel="next">chapter</a>, Previous: <a 
href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" accesskey="u" 
rel="up">top</a> &nbsp; </p>
 </div>
@@ -1066,9 +1068,9 @@ Next: <a href="#chapter" accesskey="n" 
rel="next">chapter</a>, Previous: <a href
 Next: <a href="#a-node-after-part" accesskey="n" rel="next">a node after 
part</a>, Up: <a href="#Top" accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
 <span id="chapter-1"></span><h2 class="chapter">1 chapter</h2>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/part_node_chapter_appendix.pl 
b/tp/t/results/sectioning/part_node_chapter_appendix.pl
index bafa5fa..d9c18e8 100644
--- a/tp/t/results/sectioning/part_node_chapter_appendix.pl
+++ b/tp/t/results/sectioning/part_node_chapter_appendix.pl
@@ -858,7 +858,9 @@ Next: <a href="#chapter-node" accesskey="n" 
rel="next">chapter</a> &nbsp; </p>
 
 
 <hr>
-<span id="Part-1"></span><div class="header">
+</div>
+<div class="part" id="Part-1">
+<div class="header">
 <p>
 Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -871,10 +873,12 @@ Previous: <a href="#Top" accesskey="p" 
rel="prev">top</a>, Up: <a href="#Top" ac
 <div class="chapter" id="chapter-node">
 <span id="chapter"></span><h2 class="chapter">1 chapter</h2>
 
-<span id="Appendix"></span><h2 class="appendix">Appendix A Appendix</h2>
-<hr>
 </div>
+<div class="appendix" id="Appendix">
+<h2 class="appendix">Appendix A Appendix</h2>
 </div>
+</div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/part_node_chapter_node_appendix.pl 
b/tp/t/results/sectioning/part_node_chapter_node_appendix.pl
index c2367c0..1b9a331 100644
--- a/tp/t/results/sectioning/part_node_chapter_node_appendix.pl
+++ b/tp/t/results/sectioning/part_node_chapter_node_appendix.pl
@@ -1052,7 +1052,9 @@ Next: <a href="#chapter-node" accesskey="n" 
rel="next">chapter</a> &nbsp; </p>
 
 
 <hr>
-<span id="Part-1"></span><div class="header">
+</div>
+<div class="part" id="Part-1">
+<div class="header">
 <p>
 Next: <a href="#appendix-node" accesskey="n" rel="next">Appendix</a>, 
Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -1073,9 +1075,9 @@ Next: <a href="#appendix-node" accesskey="n" 
rel="next">Appendix</a>, Previous:
 Previous: <a href="#chapter-node" accesskey="p" rel="prev">chapter</a>, Up: <a 
href="#Top" accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
 <span id="Appendix"></span><h2 class="appendix">Appendix A Appendix</h2>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/part_node_node_part_appendix.pl 
b/tp/t/results/sectioning/part_node_node_part_appendix.pl
index 72987b6..f6e4846 100644
--- a/tp/t/results/sectioning/part_node_node_part_appendix.pl
+++ b/tp/t/results/sectioning/part_node_node_part_appendix.pl
@@ -1136,7 +1136,9 @@ Next: <a href="#chapter-node" accesskey="n" 
rel="next">chapter</a> &nbsp; </p>
 
 
 <hr>
-<span id="Part-1"></span><div class="header">
+</div>
+<div class="part" id="Part-1">
+<div class="header">
 <p>
 Next: <a href="#appendix-part" accesskey="n" rel="next">Appendix</a>, 
Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -1156,16 +1158,18 @@ Next: <a href="#appendix-part" accesskey="n" 
rel="next">Appendix</a>, Previous:
 <p>
 Previous: <a href="#chapter-node" accesskey="p" rel="prev">chapter</a>, Up: <a 
href="#Top" accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
-<span id="Part-Appendix"></span><h1 class="part">Part Appendix</h1>
+</div>
+</div>
+<div class="part" id="Part-Appendix">
+<h1 class="part">Part Appendix</h1>
 <hr>
 
 <ul class="section-toc">
 <li><a href="#appendix-part" accesskey="1">Appendix</a></li>
 </ul>
 <span id="Appendix"></span><h2 class="appendix">Appendix A Appendix</h2>
-<hr>
-</div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/part_node_part_appendix.pl 
b/tp/t/results/sectioning/part_node_part_appendix.pl
index 901f59d..3202d8a 100644
--- a/tp/t/results/sectioning/part_node_part_appendix.pl
+++ b/tp/t/results/sectioning/part_node_part_appendix.pl
@@ -925,7 +925,9 @@ Next: <a href="#chapter-node" accesskey="n" 
rel="next">chapter</a> &nbsp; </p>
 
 
 <hr>
-<span id="Part-1"></span><div class="header">
+</div>
+<div class="part" id="Part-1">
+<div class="header">
 <p>
 Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -938,16 +940,20 @@ Previous: <a href="#Top" accesskey="p" 
rel="prev">top</a>, Up: <a href="#Top" ac
 <div class="chapter" id="chapter-node">
 <span id="chapter"></span><h2 class="chapter">1 chapter</h2>
 
-<span id="Part-Appendix"></span><h1 class="part">Part Appendix</h1>
+</div>
+</div>
+<div class="part" id="Part-Appendix">
+<h1 class="part">Part Appendix</h1>
 <hr>
 
 <ul class="section-toc">
 <li><a href="#Appendix" accesskey="1">Appendix</a></li>
 </ul>
-<span id="Appendix"></span><h2 class="appendix">Appendix A Appendix</h2>
-<hr>
+<div class="appendix" id="Appendix">
+<h2 class="appendix">Appendix A Appendix</h2>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/part_node_part_node_appendix.pl 
b/tp/t/results/sectioning/part_node_part_node_appendix.pl
index 8caaa8e..d8d847f 100644
--- a/tp/t/results/sectioning/part_node_part_node_appendix.pl
+++ b/tp/t/results/sectioning/part_node_part_node_appendix.pl
@@ -1126,7 +1126,9 @@ Next: <a href="#chapter-node" accesskey="n" 
rel="next">chapter</a> &nbsp; </p>
 
 
 <hr>
-<span id="Part-1"></span><div class="header">
+</div>
+<div class="part" id="Part-1">
+<div class="header">
 <p>
 Next: <a href="#appendix-node" accesskey="n" rel="next">Appendix</a>, 
Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, Up: <a href="#Top" 
accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -1140,7 +1142,10 @@ Next: <a href="#appendix-node" accesskey="n" 
rel="next">Appendix</a>, Previous:
 <span id="chapter"></span><h2 class="chapter">1 chapter</h2>
 
 <hr>
-<span id="Part-Appendix"></span><div class="header">
+</div>
+</div>
+<div class="part" id="Part-Appendix">
+<div class="header">
 <p>
 Previous: <a href="#chapter-node" accesskey="p" rel="prev">chapter</a>, Up: <a 
href="#Top" accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -1150,12 +1155,11 @@ Previous: <a href="#chapter-node" accesskey="p" 
rel="prev">chapter</a>, Up: <a h
 <ul class="section-toc">
 <li><a href="#appendix-node" accesskey="1">Appendix</a></li>
 </ul>
-</div>
 <div class="appendix" id="appendix-node">
 <span id="Appendix"></span><h2 class="appendix">Appendix A Appendix</h2>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/placed_things_before_element.pl 
b/tp/t/results/sectioning/placed_things_before_element.pl
index d2f158c..fa3b3b6 100644
--- a/tp/t/results/sectioning/placed_things_before_element.pl
+++ b/tp/t/results/sectioning/placed_things_before_element.pl
@@ -1132,7 +1132,8 @@ ul.no-bullet {list-style: none}
 
 <span id="index-index-entry"></span>
 
-<span id="section"></span><h3 class="section">1 section</h3>
+<div class="section" id="section">
+<h3 class="section">1 section</h3>
 
 <p>Ref to anchor
 <a href="#An-anchor">An anchor</a>
@@ -1151,7 +1152,8 @@ ul.no-bullet {list-style: none}
 <a href="#An-anchor">An anchor</a>
 </p>
 </div>
-<hr>
+<hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/protected_node_parentheses.pl 
b/tp/t/results/sectioning/protected_node_parentheses.pl
index f0f901a..b616ec3 100644
--- a/tp/t/results/sectioning/protected_node_parentheses.pl
+++ b/tp/t/results/sectioning/protected_node_parentheses.pl
@@ -712,8 +712,8 @@ Previous: <a href="#Top" accesskey="p" rel="prev">top</a>, 
Up: <a href="#Top" ac
 
 <span id="g_t_0028manual2_0029-name2"></span>
 <p><a href="#g_t_0028manual2_0029-name2">(manual2) name2</a>.
-</p><hr>
-</div>
+</p></div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/section_before_part.pl 
b/tp/t/results/sectioning/section_before_part.pl
index c5749d7..c564063 100644
--- a/tp/t/results/sectioning/section_before_part.pl
+++ b/tp/t/results/sectioning/section_before_part.pl
@@ -241,9 +241,12 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="section"></span><h3 class="section">1 section</h3>
+<div class="section" id="section">
+<h3 class="section">1 section</h3>
 
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <div class="Contents_element" id="SEC_Contents">
@@ -257,7 +260,8 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
-<hr>
+<hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/section_before_top.pl 
b/tp/t/results/sectioning/section_before_top.pl
index 788f8c7..b8c7afa 100644
--- a/tp/t/results/sectioning/section_before_top.pl
+++ b/tp/t/results/sectioning/section_before_top.pl
@@ -590,8 +590,8 @@ Next: <a href="#section-node" accesskey="n" 
rel="next">section</a> &nbsp; </p>
 </div>
 <span id="top"></span><h3 class="unnumberedsec">top</h3>
 
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/section_below_unnumbered.pl 
b/tp/t/results/sectioning/section_below_unnumbered.pl
index ecc2fdf..6cc559d 100644
--- a/tp/t/results/sectioning/section_below_unnumbered.pl
+++ b/tp/t/results/sectioning/section_below_unnumbered.pl
@@ -980,10 +980,10 @@ Up: <a href="#Unn" accesskey="u" rel="up">Unn</a> &nbsp; 
[<a href="#SEC_Contents
 
 <p>Should be unnumbered.
 </p>
-<hr>
 </div>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/section_below_unnumbered_no_top.pl 
b/tp/t/results/sectioning/section_below_unnumbered_no_top.pl
index ab61a02..8832e41 100644
--- a/tp/t/results/sectioning/section_below_unnumbered_no_top.pl
+++ b/tp/t/results/sectioning/section_below_unnumbered_no_top.pl
@@ -173,12 +173,16 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="U"></span><h2 class="unnumbered">U</h2>
+<div class="unnumbered" id="U">
+<h2 class="unnumbered">U</h2>
 <ul class="section-toc">
 <li><a href="#S" accesskey="1">S</a></li>
 </ul>
-<span id="S"></span><h3 class="section">S</h3>
-<hr>
+<div class="section" id="S">
+<h3 class="section">S</h3>
+<hr></div>
+</div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/section_chapter_before_top_nodes.pl 
b/tp/t/results/sectioning/section_chapter_before_top_nodes.pl
index e4cf285..7f00638 100644
--- a/tp/t/results/sectioning/section_chapter_before_top_nodes.pl
+++ b/tp/t/results/sectioning/section_chapter_before_top_nodes.pl
@@ -919,8 +919,8 @@ Next: <a href="#chapter-node" accesskey="n" 
rel="next">chapter</a> &nbsp; </p>
 <span id="top"></span><h3 class="unnumberedsec">top</h3>
 
 
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/section_in_unnumbered_info.pl 
b/tp/t/results/sectioning/section_in_unnumbered_info.pl
index 5c41a17..aec2f6b 100644
--- a/tp/t/results/sectioning/section_in_unnumbered_info.pl
+++ b/tp/t/results/sectioning/section_in_unnumbered_info.pl
@@ -8676,11 +8676,11 @@ Next: <a href="#numbered-sub2-4" accesskey="n" 
rel="next">numbered subsection2 4
 Previous: <a href="#unnumbered-sub2-4" accesskey="p" rel="prev">unnumbered 
subsection2 4</a>, Up: <a href="#unnumberedsec-4" accesskey="u" 
rel="up">unnumbered section 4</a> &nbsp; [<a href="#SEC_Contents" title="Table 
of contents" rel="contents">Contents</a>]</p>
 </div>
 <span id="numbered-subsection2-4"></span><h4 class="subsection">numbered 
subsection2 4</h4>
-<hr>
 </div>
 </div>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/section_in_unnumbered_plaintext.pl 
b/tp/t/results/sectioning/section_in_unnumbered_plaintext.pl
index 41824d3..389af70 100644
--- a/tp/t/results/sectioning/section_in_unnumbered_plaintext.pl
+++ b/tp/t/results/sectioning/section_in_unnumbered_plaintext.pl
@@ -8498,11 +8498,11 @@ Next: <a href="#numbered-sub2-4" accesskey="n" 
rel="next">numbered subsection2 4
 Previous: <a href="#unnumbered-sub2-4" accesskey="p" rel="prev">unnumbered 
subsection2 4</a>, Up: <a href="#unnumberedsec-4" accesskey="u" 
rel="up">unnumbered section 4</a> &nbsp; [<a href="#SEC_Contents" title="Table 
of contents" rel="contents">Contents</a>]</p>
 </div>
 <span id="numbered-subsection2-4"></span><h4 class="subsection">numbered 
subsection2 4</h4>
-<hr>
 </div>
 </div>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/section_node_before_part.pl 
b/tp/t/results/sectioning/section_node_before_part.pl
index 3ff0af7..642904e 100644
--- a/tp/t/results/sectioning/section_node_before_part.pl
+++ b/tp/t/results/sectioning/section_node_before_part.pl
@@ -308,7 +308,9 @@ ul.no-bullet {list-style: none}
 <div class="section" id="Top">
 <span id="section"></span><h3 class="section">1 section</h3>
 
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 <hr></div>
 
diff --git a/tp/t/results/sectioning/sections_test.pl 
b/tp/t/results/sectioning/sections_test.pl
index ddfb471..2b8eba4 100644
--- a/tp/t/results/sectioning/sections_test.pl
+++ b/tp/t/results/sectioning/sections_test.pl
@@ -762,29 +762,40 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><h1 class="top">top</h1>
+<div class="top" id="top">
+<h1 class="top">top</h1>
 
 <ul class="section-toc">
 <li><a href="#chapter" accesskey="1">chapter</a></li>
 </ul>
-<span id="chapter"></span><h2 class="chapter">1 chapter</h2>
+<div class="chapter" id="chapter">
+<h2 class="chapter">1 chapter</h2>
 
 <ul class="section-toc">
 <li><a href="#section" accesskey="1">section</a></li>
 </ul>
-<span id="section"></span><h3 class="section">1.1 section</h3>
+<div class="section" id="section">
+<h3 class="section">1.1 section</h3>
 
 <ul class="section-toc">
 <li><a href="#subsection" accesskey="1">subsection</a></li>
 </ul>
-<span id="subsection"></span><h4 class="subsection">1.1.1 subsection</h4>
+<div class="subsection" id="subsection">
+<h4 class="subsection">1.1.1 subsection</h4>
 
 <ul class="section-toc">
 <li><a href="#subsubsection" accesskey="1">subsubsection</a></li>
 </ul>
-<span id="subsubsection"></span><h4 class="subsubsection">1.1.1.1 
subsubsection</h4>
-
-<span id="part"></span><h1 class="part">part</h1>
+<div class="subsubsection" id="subsubsection">
+<h4 class="subsubsection">1.1.1.1 subsubsection</h4>
+
+</div>
+</div>
+</div>
+</div>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
@@ -792,19 +803,30 @@ ul.no-bullet {list-style: none}
 <li><a href="#second-chapter-in-part" accesskey="2">second chapter in 
part</a></li>
 <li><a href="#unnumbered" accesskey="3">unnumbered</a></li>
 </ul>
-<span id="chapter-in-part"></span><h2 class="chapter">2 chapter in part</h2>
+<div class="chapter" id="chapter-in-part">
+<h2 class="chapter">2 chapter in part</h2>
 
-<span id="second-chapter-in-part"></span><h2 class="chapter">3 second chapter 
in part</h2>
+</div>
+<div class="chapter" id="second-chapter-in-part">
+<h2 class="chapter">3 second chapter in part</h2>
 
-<span id="unnumbered"></span><h2 class="unnumbered">unnumbered</h2>
+</div>
+<div class="unnumbered" id="unnumbered">
+<h2 class="unnumbered">unnumbered</h2>
 
-<span id="appendix"></span><h2 class="appendix">Appendix A appendix</h2>
+</div>
+<div class="appendix" id="appendix">
+<h2 class="appendix">Appendix A appendix</h2>
 
 <ul class="section-toc">
 <li><a href="#appendixsec" accesskey="1">appendixsec</a></li>
 </ul>
-<span id="appendixsec"></span><h3 class="appendixsec">A.1 appendixsec</h3>
-<hr>
+<div class="appendixsec" id="appendixsec">
+<h3 class="appendixsec">A.1 appendixsec</h3>
+<hr></div>
+</div>
+</div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/sections_test_no_use_nodes.pl 
b/tp/t/results/sectioning/sections_test_no_use_nodes.pl
index dc983bd..1341894 100644
--- a/tp/t/results/sectioning/sections_test_no_use_nodes.pl
+++ b/tp/t/results/sectioning/sections_test_no_use_nodes.pl
@@ -763,7 +763,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><div class="header">
+<div class="top" id="top">
+<div class="header">
 <p>
 Next: <a href="#chapter-in-part" accesskey="n" rel="next">chapter in part</a> 
&nbsp; </p>
 </div>
@@ -773,7 +774,8 @@ Next: <a href="#chapter-in-part" accesskey="n" 
rel="next">chapter in part</a> &n
 <li><a href="#chapter" accesskey="1">chapter</a></li>
 </ul>
 <hr>
-<span id="chapter"></span><div class="header">
+<div class="chapter" id="chapter">
+<div class="header">
 <p>
  Up : <a href="#top" accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
@@ -783,7 +785,8 @@ Next: <a href="#chapter-in-part" accesskey="n" 
rel="next">chapter in part</a> &n
 <li><a href="#section" accesskey="1">section</a></li>
 </ul>
 <hr>
-<span id="section"></span><div class="header">
+<div class="section" id="section">
+<div class="header">
 <p>
  Up : <a href="#chapter" accesskey="u" rel="up">chapter</a> &nbsp; </p>
 </div>
@@ -793,7 +796,8 @@ Next: <a href="#chapter-in-part" accesskey="n" 
rel="next">chapter in part</a> &n
 <li><a href="#subsection" accesskey="1">subsection</a></li>
 </ul>
 <hr>
-<span id="subsection"></span><div class="header">
+<div class="subsection" id="subsection">
+<div class="header">
 <p>
  Up : <a href="#section" accesskey="u" rel="up">section</a> &nbsp; </p>
 </div>
@@ -803,14 +807,21 @@ Next: <a href="#chapter-in-part" accesskey="n" 
rel="next">chapter in part</a> &n
 <li><a href="#subsubsection" accesskey="1">subsubsection</a></li>
 </ul>
 <hr>
-<span id="subsubsection"></span><div class="header">
+<div class="subsubsection" id="subsubsection">
+<div class="header">
 <p>
  Up : <a href="#subsection" accesskey="u" rel="up">subsection</a> &nbsp; </p>
 </div>
 <h4 class="subsubsection">1.1.1.1 subsubsection</h4>
 
 <hr>
-<span id="part"></span><div class="header">
+</div>
+</div>
+</div>
+</div>
+</div>
+<div class="part" id="part">
+<div class="header">
 <p>
 Next: <a href="#second-chapter-in-part" accesskey="n" rel="next">second 
chapter in part</a> &nbsp; </p>
 </div>
@@ -822,24 +833,31 @@ Next: <a href="#second-chapter-in-part" accesskey="n" 
rel="next">second chapter
 <li><a href="#second-chapter-in-part" accesskey="2">second chapter in 
part</a></li>
 <li><a href="#unnumbered" accesskey="3">unnumbered</a></li>
 </ul>
-<span id="chapter-in-part"></span><h2 class="chapter">2 chapter in part</h2>
+<div class="chapter" id="chapter-in-part">
+<h2 class="chapter">2 chapter in part</h2>
 
 <hr>
-<span id="second-chapter-in-part"></span><div class="header">
+</div>
+<div class="chapter" id="second-chapter-in-part">
+<div class="header">
 <p>
 Next: <a href="#unnumbered" accesskey="n" rel="next">unnumbered</a>, Prev: <a 
href="#chapter-in-part" accesskey="p" rel="prev">chapter in part</a>,  Up : <a 
href="#chapter-in-part" accesskey="u" rel="up">chapter in part</a> &nbsp; </p>
 </div>
 <h2 class="chapter">3 second chapter in part</h2>
 
 <hr>
-<span id="unnumbered"></span><div class="header">
+</div>
+<div class="unnumbered" id="unnumbered">
+<div class="header">
 <p>
 Prev: <a href="#second-chapter-in-part" accesskey="p" rel="prev">second 
chapter in part</a>,  Up : <a href="#chapter-in-part" accesskey="u" 
rel="up">chapter in part</a> &nbsp; </p>
 </div>
 <h2 class="unnumbered">unnumbered</h2>
 
 <hr>
-<span id="appendix"></span><div class="header">
+</div>
+<div class="appendix" id="appendix">
+<div class="header">
 <p>
 Prev: <a href="#chapter-in-part" accesskey="p" rel="prev">chapter in part</a> 
&nbsp; </p>
 </div>
@@ -849,11 +867,15 @@ Prev: <a href="#chapter-in-part" accesskey="p" 
rel="prev">chapter in part</a> &n
 <li><a href="#appendixsec" accesskey="1">appendixsec</a></li>
 </ul>
 <hr>
-<span id="appendixsec"></span><div class="header">
+<div class="appendixsec" id="appendixsec">
+<div class="header">
 <p>
  Up : <a href="#appendix" accesskey="u" rel="up">appendix</a> &nbsp; </p>
 </div>
 <h3 class="appendixsec">A.1 appendixsec</h3>
+</div>
+</div>
+</div>
 <hr>
 
 
diff --git 
a/tp/t/results/sectioning/sections_test_no_use_nodes_use_node_directions.pl 
b/tp/t/results/sectioning/sections_test_no_use_nodes_use_node_directions.pl
index 4719bc9..b1fa430 100644
--- a/tp/t/results/sectioning/sections_test_no_use_nodes_use_node_directions.pl
+++ b/tp/t/results/sectioning/sections_test_no_use_nodes_use_node_directions.pl
@@ -763,7 +763,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><div class="header">
+<div class="top" id="top">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
@@ -773,7 +774,8 @@ ul.no-bullet {list-style: none}
 <li><a href="#chapter" accesskey="1">chapter</a></li>
 </ul>
 <hr>
-<span id="chapter"></span><div class="header">
+<div class="chapter" id="chapter">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
@@ -783,7 +785,8 @@ ul.no-bullet {list-style: none}
 <li><a href="#section" accesskey="1">section</a></li>
 </ul>
 <hr>
-<span id="section"></span><div class="header">
+<div class="section" id="section">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
@@ -793,7 +796,8 @@ ul.no-bullet {list-style: none}
 <li><a href="#subsection" accesskey="1">subsection</a></li>
 </ul>
 <hr>
-<span id="subsection"></span><div class="header">
+<div class="subsection" id="subsection">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
@@ -803,14 +807,21 @@ ul.no-bullet {list-style: none}
 <li><a href="#subsubsection" accesskey="1">subsubsection</a></li>
 </ul>
 <hr>
-<span id="subsubsection"></span><div class="header">
+<div class="subsubsection" id="subsubsection">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
 <h4 class="subsubsection">1.1.1.1 subsubsection</h4>
 
 <hr>
-<span id="part"></span><div class="header">
+</div>
+</div>
+</div>
+</div>
+</div>
+<div class="part" id="part">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
@@ -822,24 +833,31 @@ ul.no-bullet {list-style: none}
 <li><a href="#second-chapter-in-part" accesskey="2">second chapter in 
part</a></li>
 <li><a href="#unnumbered" accesskey="3">unnumbered</a></li>
 </ul>
-<span id="chapter-in-part"></span><h2 class="chapter">2 chapter in part</h2>
+<div class="chapter" id="chapter-in-part">
+<h2 class="chapter">2 chapter in part</h2>
 
 <hr>
-<span id="second-chapter-in-part"></span><div class="header">
+</div>
+<div class="chapter" id="second-chapter-in-part">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
 <h2 class="chapter">3 second chapter in part</h2>
 
 <hr>
-<span id="unnumbered"></span><div class="header">
+</div>
+<div class="unnumbered" id="unnumbered">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
 <h2 class="unnumbered">unnumbered</h2>
 
 <hr>
-<span id="appendix"></span><div class="header">
+</div>
+<div class="appendix" id="appendix">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
@@ -849,11 +867,15 @@ ul.no-bullet {list-style: none}
 <li><a href="#appendixsec" accesskey="1">appendixsec</a></li>
 </ul>
 <hr>
-<span id="appendixsec"></span><div class="header">
+<div class="appendixsec" id="appendixsec">
+<div class="header">
 <p>
  &nbsp; </p>
 </div>
 <h3 class="appendixsec">A.1 appendixsec</h3>
+</div>
+</div>
+</div>
 <hr>
 
 
diff --git a/tp/t/results/sectioning/shortcontents.pl 
b/tp/t/results/sectioning/shortcontents.pl
index f2b3deb..92e9d32 100644
--- a/tp/t/results/sectioning/shortcontents.pl
+++ b/tp/t/results/sectioning/shortcontents.pl
@@ -799,7 +799,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top"></span><h1 class="top">top</h1>
+<div class="top" id="top">
+<h1 class="top">top</h1>
 
 <div class="Overview_element" id="SEC_Overview">
 <h2 class="shortcontents-heading">Short Table of Contents</h2>
@@ -819,24 +820,34 @@ ul.no-bullet {list-style: none}
 </ul>
 </div>
 </div>
-<span id="chapter"></span><h2 class="chapter">1 chapter</h2>
+<div class="chapter" id="chapter">
+<h2 class="chapter">1 chapter</h2>
 
 <ul class="section-toc">
 <li><a href="#section" accesskey="1">section</a></li>
 </ul>
-<span id="section"></span><h3 class="section">1.1 section</h3>
+<div class="section" id="section">
+<h3 class="section">1.1 section</h3>
 
 <ul class="section-toc">
 <li><a href="#subsection" accesskey="1">subsection</a></li>
 </ul>
-<span id="subsection"></span><h4 class="subsection">1.1.1 subsection</h4>
+<div class="subsection" id="subsection">
+<h4 class="subsection">1.1.1 subsection</h4>
 
 <ul class="section-toc">
 <li><a href="#subsubsection" accesskey="1">subsubsection</a></li>
 </ul>
-<span id="subsubsection"></span><h4 class="subsubsection">1.1.1.1 
subsubsection</h4>
+<div class="subsubsection" id="subsubsection">
+<h4 class="subsubsection">1.1.1.1 subsubsection</h4>
 
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+</div>
+</div>
+</div>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <ul class="section-toc">
@@ -844,20 +855,31 @@ ul.no-bullet {list-style: none}
 <li><a href="#second-chapter-in-part" accesskey="2">second chapter in 
part</a></li>
 <li><a href="#unnumbered" accesskey="3">unnumbered</a></li>
 </ul>
-<span id="chapter-in-part"></span><h2 class="chapter">2 chapter in part</h2>
+<div class="chapter" id="chapter-in-part">
+<h2 class="chapter">2 chapter in part</h2>
 
-<span id="second-chapter-in-part"></span><h2 class="chapter">3 second chapter 
in part</h2>
+</div>
+<div class="chapter" id="second-chapter-in-part">
+<h2 class="chapter">3 second chapter in part</h2>
 
-<span id="unnumbered"></span><h2 class="unnumbered">unnumbered</h2>
+</div>
+<div class="unnumbered" id="unnumbered">
+<h2 class="unnumbered">unnumbered</h2>
 
-<span id="appendix"></span><h2 class="appendix">Appendix A appendix</h2>
+</div>
+<div class="appendix" id="appendix">
+<h2 class="appendix">Appendix A appendix</h2>
 
 <ul class="section-toc">
 <li><a href="#appendixsec" accesskey="1">appendixsec</a></li>
 </ul>
-<span id="appendixsec"></span><h3 class="appendixsec">A.1 appendixsec</h3>
+<div class="appendixsec" id="appendixsec">
+<h3 class="appendixsec">A.1 appendixsec</h3>
+
+<hr></div>
+</div>
+</div>
 
-<hr>
 
 
 </body>
diff --git a/tp/t/results/sectioning/top_no_argument_and_content.pl 
b/tp/t/results/sectioning/top_no_argument_and_content.pl
index 545482e..14fd6e4 100644
--- a/tp/t/results/sectioning/top_no_argument_and_content.pl
+++ b/tp/t/results/sectioning/top_no_argument_and_content.pl
@@ -134,9 +134,11 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="SEC_Top"></span>
+<div class="top" id="SEC_Top">
+
 <p>A.
-</p><hr>
+</p><hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/top_node_part_top.pl 
b/tp/t/results/sectioning/top_node_part_top.pl
index 17774c3..3706f3f 100644
--- a/tp/t/results/sectioning/top_node_part_top.pl
+++ b/tp/t/results/sectioning/top_node_part_top.pl
@@ -369,7 +369,9 @@ ul.no-bullet {list-style: none}
 <body lang="en">
 <div class="top" id="Top">
 
-<span id="part"></span><h1 class="part">part</h1>
+</div>
+<div class="part" id="part">
+<h1 class="part">part</h1>
 <hr>
 
 <span id="top"></span><h1 class="top">top</h1>
diff --git a/tp/t/results/sectioning/top_node_up_url.pl 
b/tp/t/results/sectioning/top_node_up_url.pl
index 8133fbe..e21f122 100644
--- a/tp/t/results/sectioning/top_node_up_url.pl
+++ b/tp/t/results/sectioning/top_node_up_url.pl
@@ -585,8 +585,8 @@ Next: <a href="#first" accesskey="n" rel="next">first</a>, 
Up: <a href="http://w
 Previous: <a href="#Top" accesskey="p" rel="prev">internal top node up</a>, 
Up: <a href="#Top" accesskey="u" rel="up">internal top node up</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">first</h4>
-<hr>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/top_without_node_nodes.pl 
b/tp/t/results/sectioning/top_without_node_nodes.pl
index 5493cf6..d486cd4 100644
--- a/tp/t/results/sectioning/top_without_node_nodes.pl
+++ b/tp/t/results/sectioning/top_without_node_nodes.pl
@@ -444,7 +444,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top-section"></span><h1 class="top">top section</h1>
+<div class="top" id="top-section">
+<h1 class="top">top section</h1>
 <p>Top section
 </p>
 <ul class="section-toc">
@@ -455,6 +456,7 @@ ul.no-bullet {list-style: none}
 
 <p>Text of chapter
 </p><hr></div>
+</div>
 
 
 
diff --git a/tp/t/results/sectioning/top_without_node_sections.pl 
b/tp/t/results/sectioning/top_without_node_sections.pl
index 6d16f46..9916a4c 100644
--- a/tp/t/results/sectioning/top_without_node_sections.pl
+++ b/tp/t/results/sectioning/top_without_node_sections.pl
@@ -492,7 +492,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="top-section"></span><h1 class="top">top section</h1>
+<div class="top" id="top-section">
+<h1 class="top">top section</h1>
 <p>Top section
 </p>
 <ul class="section-toc">
@@ -503,6 +504,7 @@ ul.no-bullet {list-style: none}
 
 <p>Text of chapter
 </p><hr></div>
+</div>
 
 
 
diff --git a/tp/t/results/sectioning/two_nodes_at_the_end.pl 
b/tp/t/results/sectioning/two_nodes_at_the_end.pl
index 0fa10a2..0bf1ca0 100644
--- a/tp/t/results/sectioning/two_nodes_at_the_end.pl
+++ b/tp/t/results/sectioning/two_nodes_at_the_end.pl
@@ -1065,9 +1065,9 @@ Next: <a href="#node-after-chapter-2" accesskey="n" 
rel="next">node after chapte
 Previous: <a href="#node-after-chapter-1" accesskey="p" rel="prev">node after 
chapter 1</a>, Up: <a href="#Top" accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
 <h4 class="node-heading">node after chapter 2</h4>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/two_nodes_between_chapters.pl 
b/tp/t/results/sectioning/two_nodes_between_chapters.pl
index c7a7c52..66e76b6 100644
--- a/tp/t/results/sectioning/two_nodes_between_chapters.pl
+++ b/tp/t/results/sectioning/two_nodes_between_chapters.pl
@@ -1226,9 +1226,9 @@ Next: <a href="#chapter-2" accesskey="n" 
rel="next">chapter c2</a>, Previous: <a
 Previous: <a href="#chapter-1" accesskey="p" rel="prev">chapter c1</a>, Up: <a 
href="#Top" accesskey="u" rel="up">top</a> &nbsp; </p>
 </div>
 <span id="chapter-c2"></span><h2 class="chapter">2 chapter c2</h2>
-<hr>
 </div>
 </div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/unnumbered_before_node_top_top.pl 
b/tp/t/results/sectioning/unnumbered_before_node_top_top.pl
index 4763c94..b6f70a4 100644
--- a/tp/t/results/sectioning/unnumbered_before_node_top_top.pl
+++ b/tp/t/results/sectioning/unnumbered_before_node_top_top.pl
@@ -427,10 +427,12 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="before-nodes"></span><h2 class="unnumbered">before nodes</h2>
+<div class="unnumbered" id="before-nodes">
+<h2 class="unnumbered">before nodes</h2>
 
 <p>in unnumbered
 </p>
+</div>
 <div class="top" id="Top">
 <span id="top-section"></span><h2 class="unnumbered">top section</h2>
 <p>Top node
diff --git a/tp/t/results/sectioning/unnumbered_before_top_node.pl 
b/tp/t/results/sectioning/unnumbered_before_top_node.pl
index 7135314..eaae38a 100644
--- a/tp/t/results/sectioning/unnumbered_before_top_node.pl
+++ b/tp/t/results/sectioning/unnumbered_before_top_node.pl
@@ -310,13 +310,15 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="before-nodes"></span><h2 class="unnumbered">before nodes</h2>
+<div class="unnumbered" id="before-nodes">
+<h2 class="unnumbered">before nodes</h2>
 
 <span id="Top"></span><h1 class="node-heading">Top</h1>
 <p>Top node
 </p>
 <h1 class="titlefont">Title titlefont</h1>
-<hr>
+<hr></div>
+
 
 
 </body>
diff --git a/tp/t/results/sectioning/unnumbered_top_without_node_nodes.pl 
b/tp/t/results/sectioning/unnumbered_top_without_node_nodes.pl
index 89a931d..8e295d5 100644
--- a/tp/t/results/sectioning/unnumbered_top_without_node_nodes.pl
+++ b/tp/t/results/sectioning/unnumbered_top_without_node_nodes.pl
@@ -727,7 +727,9 @@ Up: <a href="dir.html#Top" accesskey="u" rel="up">(dir)</a> 
&nbsp; </p>
 
 <p>in unnumbered
 </p>
-<span id="top-section"></span><h2 class="unnumbered">top section</h2>
+</div>
+<div class="top" id="top-section">
+<h2 class="unnumbered">top section</h2>
 <p>Top section
 </p>
 <hr>
@@ -740,8 +742,8 @@ Up: <a href="dir.html#Top" accesskey="u" rel="up">(dir)</a> 
&nbsp; </p>
 <span id="Chapter"></span><h2 class="chapter">1 Chapter</h2>
 
 <p>Text of chapter
-</p><hr>
-</div>
+</p></div>
+<hr>
 
 
 
diff --git a/tp/t/results/sectioning/unnumbered_top_without_node_sections.pl 
b/tp/t/results/sectioning/unnumbered_top_without_node_sections.pl
index 45a2d46..ba28acc 100644
--- a/tp/t/results/sectioning/unnumbered_top_without_node_sections.pl
+++ b/tp/t/results/sectioning/unnumbered_top_without_node_sections.pl
@@ -781,7 +781,9 @@ Up: <a href="dir.html#Top" accesskey="u" rel="up">(dir)</a> 
&nbsp; </p>
 
 <p>in unnumbered
 </p>
-<span id="top-section"></span><h2 class="unnumbered">top section</h2>
+</div>
+<div class="top" id="top-section">
+<h2 class="unnumbered">top section</h2>
 <p>Top section
 </p>
 <hr>
@@ -794,8 +796,8 @@ Up: <a href="dir.html#Top" accesskey="u" rel="up">(dir)</a> 
&nbsp; </p>
 <span id="Chapter"></span><h2 class="chapter">1 Chapter</h2>
 
 <p>Text of chapter
-</p><hr>
-</div>
+</p></div>
+<hr>
 
 
 
diff --git 
a/tp/tests/contents/res_parser/contents_and_parts/contents_and_parts.html 
b/tp/tests/contents/res_parser/contents_and_parts/contents_and_parts.html
index 7675df1..ad0bf8d 100644
--- a/tp/tests/contents/res_parser/contents_and_parts/contents_and_parts.html
+++ b/tp/tests/contents/res_parser/contents_and_parts/contents_and_parts.html
@@ -58,7 +58,9 @@ ul.no-bullet {list-style: none}
 </table>
 
 <hr size="6">
-<span id="part-1_003a-part-1"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+</div>
+<div class="part" id="part-1_003a-part-1">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#Top" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Up section"> Up 
</a>]</td>
@@ -100,7 +102,10 @@ ul.no-bullet {list-style: none}
 <span id="chapter-2"></span><h1 class="chapter">2 chapter 2</h1>
 
 <hr>
-<span id="part2_003a-part2"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+</div>
+</div>
+<div class="part" id="part2_003a-part2">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter-2-node" 
title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#chapter-2-node" title="Previous 
section in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Up section"> Up 
</a>]</td>
@@ -118,7 +123,6 @@ ul.no-bullet {list-style: none}
 <h1 class="part">part2: part2</h1>
 <hr>
 
-</div>
 <div class="chapter" id="chapter-3-node">
 <span id="chapter-3"></span><h1 class="chapter">3 chapter 3</h1>
 
diff --git 
a/tp/tests/contents/res_parser/double_contents_after_title_book_chapter/chapter.html
 
b/tp/tests/contents/res_parser/double_contents_after_title_book_chapter/chapter.html
index 009d8fa..a0fbb9b 100644
--- 
a/tp/tests/contents/res_parser/double_contents_after_title_book_chapter/chapter.html
+++ 
b/tp/tests/contents/res_parser/double_contents_after_title_book_chapter/chapter.html
@@ -80,6 +80,8 @@ ul.no-bullet {list-style: none}
 </tr></table>
 <span id="section-with-contents"></span><h2 class="section">1.1 section with 
contents</h2>
 
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -94,8 +96,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_after_title_book_chapter/index.html
 
b/tp/tests/contents/res_parser/double_contents_after_title_book_chapter/index.html
index 8d4e8d6..38a9026 100644
--- 
a/tp/tests/contents/res_parser/double_contents_after_title_book_chapter/index.html
+++ 
b/tp/tests/contents/res_parser/double_contents_after_title_book_chapter/index.html
@@ -70,6 +70,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -79,7 +80,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_after_title_no_texi2html/index.html
 
b/tp/tests/contents/res_parser/double_contents_after_title_no_texi2html/index.html
index ccb6d90..88e4fce 100644
--- 
a/tp/tests/contents/res_parser/double_contents_after_title_no_texi2html/index.html
+++ 
b/tp/tests/contents/res_parser/double_contents_after_title_no_texi2html/index.html
@@ -69,12 +69,12 @@ Next: <a href="chapter.html" accesskey="n" 
rel="next">Chapter 1</a> &nbsp; [<a h
 <ul class="section-toc">
 <li><a href="chapter.html" accesskey="1">Chapter 1</a></li>
 </ul>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="chapter.html" accesskey="n" rel="next">Chapter 1</a> &nbsp; [<a 
href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
 </div>
-</div>
 
 
 
diff --git a/tp/tests/contents/res_parser/double_contents_chapter/chapter.html 
b/tp/tests/contents/res_parser/double_contents_chapter/chapter.html
index 79a6322..96ddea4 100644
--- a/tp/tests/contents/res_parser/double_contents_chapter/chapter.html
+++ b/tp/tests/contents/res_parser/double_contents_chapter/chapter.html
@@ -80,6 +80,8 @@ ul.no-bullet {list-style: none}
 </tr></table>
 <span id="section-with-contents"></span><h2 class="section">1.1 section with 
contents</h2>
 
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -94,8 +96,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/contents/res_parser/double_contents_chapter/index.html 
b/tp/tests/contents/res_parser/double_contents_chapter/index.html
index 3b14db5..11222f7 100644
--- a/tp/tests/contents/res_parser/double_contents_chapter/index.html
+++ b/tp/tests/contents/res_parser/double_contents_chapter/index.html
@@ -56,6 +56,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -65,7 +66,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_inline_chapter/chapter.html 
b/tp/tests/contents/res_parser/double_contents_inline_chapter/chapter.html
index 1bc0707..57afb8a 100644
--- a/tp/tests/contents/res_parser/double_contents_inline_chapter/chapter.html
+++ b/tp/tests/contents/res_parser/double_contents_inline_chapter/chapter.html
@@ -106,6 +106,8 @@ ul.no-bullet {list-style: none}
 </div>
 </div>
 
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -120,8 +122,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_inline_chapter/index.html 
b/tp/tests/contents/res_parser/double_contents_inline_chapter/index.html
index 978b52c..6c2ba13 100644
--- a/tp/tests/contents/res_parser/double_contents_inline_chapter/index.html
+++ b/tp/tests/contents/res_parser/double_contents_inline_chapter/index.html
@@ -69,6 +69,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -78,7 +79,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_inline_nodes/chapter.html 
b/tp/tests/contents/res_parser/double_contents_inline_nodes/chapter.html
index 8c86d46..749456a 100644
--- a/tp/tests/contents/res_parser/double_contents_inline_nodes/chapter.html
+++ b/tp/tests/contents/res_parser/double_contents_inline_nodes/chapter.html
@@ -75,8 +75,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_inline_nodes/index.html 
b/tp/tests/contents/res_parser/double_contents_inline_nodes/index.html
index 1d02bde..cb09dec 100644
--- a/tp/tests/contents/res_parser/double_contents_inline_nodes/index.html
+++ b/tp/tests/contents/res_parser/double_contents_inline_nodes/index.html
@@ -70,6 +70,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -79,7 +80,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_inline_nodes/section.html 
b/tp/tests/contents/res_parser/double_contents_inline_nodes/section.html
index 09edc24..e24e5f9 100644
--- a/tp/tests/contents/res_parser/double_contents_inline_nodes/section.html
+++ b/tp/tests/contents/res_parser/double_contents_inline_nodes/section.html
@@ -68,8 +68,8 @@ ul.no-bullet {list-style: none}
 </div>
 </div>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_inline_section/chapter.html 
b/tp/tests/contents/res_parser/double_contents_inline_section/chapter.html
index 200d339..e3a82bb 100644
--- a/tp/tests/contents/res_parser/double_contents_inline_section/chapter.html
+++ b/tp/tests/contents/res_parser/double_contents_inline_section/chapter.html
@@ -74,6 +74,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -82,7 +83,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="section.html" title="Next section 
in reading order"> &gt; </a>]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_inline_section/index.html 
b/tp/tests/contents/res_parser/double_contents_inline_section/index.html
index bd51c64..a9df6a1 100644
--- a/tp/tests/contents/res_parser/double_contents_inline_section/index.html
+++ b/tp/tests/contents/res_parser/double_contents_inline_section/index.html
@@ -69,6 +69,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -78,7 +79,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/contents/res_parser/double_contents_inline_section/section.html 
b/tp/tests/contents/res_parser/double_contents_inline_section/section.html
index d1b357a..e32ac4e 100644
--- a/tp/tests/contents/res_parser/double_contents_inline_section/section.html
+++ b/tp/tests/contents/res_parser/double_contents_inline_section/section.html
@@ -67,6 +67,7 @@ ul.no-bullet {list-style: none}
 </div>
 </div>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -75,7 +76,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[ &gt; ]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/contents/res_parser/double_contents_nodes/chapter.html 
b/tp/tests/contents/res_parser/double_contents_nodes/chapter.html
index a930d01..89e83c6 100644
--- a/tp/tests/contents/res_parser/double_contents_nodes/chapter.html
+++ b/tp/tests/contents/res_parser/double_contents_nodes/chapter.html
@@ -62,8 +62,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/contents/res_parser/double_contents_nodes/index.html 
b/tp/tests/contents/res_parser/double_contents_nodes/index.html
index 770f065..f5170bd 100644
--- a/tp/tests/contents/res_parser/double_contents_nodes/index.html
+++ b/tp/tests/contents/res_parser/double_contents_nodes/index.html
@@ -57,6 +57,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -66,7 +67,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/contents/res_parser/double_contents_nodes/section.html 
b/tp/tests/contents/res_parser/double_contents_nodes/section.html
index b107916..d1d395c 100644
--- a/tp/tests/contents/res_parser/double_contents_nodes/section.html
+++ b/tp/tests/contents/res_parser/double_contents_nodes/section.html
@@ -55,8 +55,8 @@ ul.no-bullet {list-style: none}
 <hr>
 <span id="section-with-contents"></span><h2 class="section">1.1 section with 
contents</h2>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/contents/res_parser/double_contents_section/chapter.html 
b/tp/tests/contents/res_parser/double_contents_section/chapter.html
index 6a65ab5..882bd1d 100644
--- a/tp/tests/contents/res_parser/double_contents_section/chapter.html
+++ b/tp/tests/contents/res_parser/double_contents_section/chapter.html
@@ -61,6 +61,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -69,7 +70,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="section.html" title="Next section 
in reading order"> &gt; </a>]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/contents/res_parser/double_contents_section/index.html 
b/tp/tests/contents/res_parser/double_contents_section/index.html
index e7d1fb4..6bec9dc 100644
--- a/tp/tests/contents/res_parser/double_contents_section/index.html
+++ b/tp/tests/contents/res_parser/double_contents_section/index.html
@@ -56,6 +56,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -65,7 +66,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="double_contents_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/contents/res_parser/double_contents_section/section.html 
b/tp/tests/contents/res_parser/double_contents_section/section.html
index 07eccc6..89773c8 100644
--- a/tp/tests/contents/res_parser/double_contents_section/section.html
+++ b/tp/tests/contents/res_parser/double_contents_section/section.html
@@ -54,6 +54,7 @@ ul.no-bullet {list-style: none}
 </tr></table>
 <span id="section-with-contents"></span><h2 class="section">1.1 section with 
contents</h2>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -62,7 +63,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[ &gt; ]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_no_node_no_top/index_no_node_no_top.html 
b/tp/tests/indices/res_parser/index_no_node_no_top/index_no_node_no_top.html
index d13db48..85d535a 100644
--- a/tp/tests/indices/res_parser/index_no_node_no_top/index_no_node_no_top.html
+++ b/tp/tests/indices/res_parser/index_no_node_no_top/index_no_node_no_top.html
@@ -85,7 +85,8 @@ ul.no-bullet {list-style: none}
 </td></tr></table>
 
 
-<span id="unnumbered"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="unnumbered" id="unnumbered">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt;&lt; ]</td>
 <td valign="middle" align="left">[ &lt; ]</td>
 <td valign="middle" align="left">[ Up ]</td>
@@ -152,7 +153,9 @@ ul.no-bullet {list-style: none}
 </td></tr></table>
 
 <hr>
-<span id="top-_0028chapter_0029-section"></span><table class="header" 
cellpadding="1" cellspacing="1" border="0">
+</div>
+<div class="unnumbered" id="top-_0028chapter_0029-section">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#unnumbered" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#unnumbered" title="Previous 
section in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[ Up ]</td>
@@ -226,7 +229,8 @@ ul.no-bullet {list-style: none}
 
 
 <hr>
-<span id="second"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+<div class="section" id="second">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#top-_0028chapter_0029-section" 
title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#top-_0028chapter_0029-section" 
title="Previous section in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#top-_0028chapter_0029-section" 
title="Up section"> Up </a>]</td>
@@ -336,7 +340,10 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 <hr>
-<span id="Chapter"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+</div>
+</div>
+<div class="chapter" id="Chapter">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#top-_0028chapter_0029-section" 
title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#second" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[ Up ]</td>
@@ -402,7 +409,9 @@ ul.no-bullet {list-style: none}
 <span id="index-Chapter2"></span>
 </p>
 <hr>
-<span id="Chapter-2"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+</div>
+<div class="chapter" id="Chapter-2">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#Chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Chapter" title="Previous section 
in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[ Up ]</td>
@@ -422,6 +431,7 @@ ul.no-bullet {list-style: none}
 <p>In chapter 2
 </p>
 <hr size="6">
+</div>
 <div class="About_element" id="SEC_About">
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#unnumbered" title="Cover (top) 
of document">Top</a>]</td>
diff --git a/tp/tests/indices/res_parser/index_special_region/Chapter.html 
b/tp/tests/indices/res_parser/index_special_region/Chapter.html
index 2c144f3..0469b3c 100644
--- a/tp/tests/indices/res_parser/index_special_region/Chapter.html
+++ b/tp/tests/indices/res_parser/index_special_region/Chapter.html
@@ -42,7 +42,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="Chapter"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="chapter" id="Chapter">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Previous section 
in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Up section"> Up 
</a>]</td>
@@ -116,6 +117,7 @@ and titlepage, and various wrong index entries.
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git 
a/tp/tests/indices/res_parser/index_special_region/Copying-and-indices.html 
b/tp/tests/indices/res_parser/index_special_region/Copying-and-indices.html
index 0d39a8c..e413612 100644
--- a/tp/tests/indices/res_parser/index_special_region/Copying-and-indices.html
+++ b/tp/tests/indices/res_parser/index_special_region/Copying-and-indices.html
@@ -160,6 +160,7 @@ domain<a id="DOCF1_2" 
href="index_special_region_fot.html#FOOT1_2"><sup>2</sup><
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -174,7 +175,6 @@ domain<a id="DOCF1_2" 
href="index_special_region_fot.html#FOOT1_2"><sup>2</sup><
 <td valign="middle" align="left">[<a href="Chapter.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/indices/res_parser/index_special_region/index.html 
b/tp/tests/indices/res_parser/index_special_region/index.html
index e7baf58..b2dd3a5 100644
--- a/tp/tests/indices/res_parser/index_special_region/index.html
+++ b/tp/tests/indices/res_parser/index_special_region/index.html
@@ -55,6 +55,7 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a 
href="index_special_region_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
 <span id="Top-1"></span><h1 class="top">Top</h1>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -64,7 +65,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="Chapter.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/indices/res_parser/index_special_region_html/Chapter.html 
b/tp/tests/indices/res_parser/index_special_region_html/Chapter.html
index d6187d3..1c5ae69 100644
--- a/tp/tests/indices/res_parser/index_special_region_html/Chapter.html
+++ b/tp/tests/indices/res_parser/index_special_region_html/Chapter.html
@@ -42,7 +42,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="Chapter"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="chapter" id="Chapter">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Previous section 
in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Up section"> Up 
</a>]</td>
@@ -116,6 +117,7 @@ and titlepage, and various wrong index entries.
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_html/Copying-and-indices.html
 
b/tp/tests/indices/res_parser/index_special_region_html/Copying-and-indices.html
index 88cf7f4..4b0c127 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_html/Copying-and-indices.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_html/Copying-and-indices.html
@@ -160,6 +160,7 @@ domain<a id="DOCF1_4" 
href="index_special_region_fot.html#FOOT1_4"><sup>4</sup><
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -174,7 +175,6 @@ domain<a id="DOCF1_4" 
href="index_special_region_fot.html#FOOT1_4"><sup>4</sup><
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/indices/res_parser/index_special_region_html/index.html 
b/tp/tests/indices/res_parser/index_special_region_html/index.html
index 96e4c1e..d71c9ea 100644
--- a/tp/tests/indices/res_parser/index_special_region_html/index.html
+++ b/tp/tests/indices/res_parser/index_special_region_html/index.html
@@ -97,6 +97,7 @@ domain<a id="DOCF1" 
href="index_special_region_fot.html#FOOT1"><sup>2</sup></a>.
 <td valign="middle" align="left">[<a 
href="index_special_region_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
 <span id="Top-1"></span><h1 class="top">Top</h1>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -106,7 +107,6 @@ domain<a id="DOCF1" 
href="index_special_region_fot.html#FOOT1"><sup>2</sup></a>.
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying/Chapter.html
 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying/Chapter.html
index 879c7d5..b12aff8 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying/Chapter.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying/Chapter.html
@@ -42,7 +42,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="Chapter"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="chapter" id="Chapter">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Previous section 
in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Up section"> Up 
</a>]</td>
@@ -80,6 +81,7 @@ and titlepage, and various wrong index entries.
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying/Copying-and-indices.html
 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying/Copying-and-indices.html
index d11506c..5b7ae65 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying/Copying-and-indices.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying/Copying-and-indices.html
@@ -124,6 +124,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -138,7 +139,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_no_insertcopying_abt.html#SEC_About" title="About 
(help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying/index.html 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying/index.html
index 6ea1641..97875c4 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying/index.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying/index.html
@@ -55,6 +55,7 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a 
href="index_special_region_no_insertcopying_abt.html#SEC_About" title="About 
(help)"> ? </a>]</td>
 </tr></table>
 <span id="Top-1"></span><h1 class="top">Top</h1>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -64,7 +65,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_no_insertcopying_abt.html#SEC_About" title="About 
(help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/Chapter.html
 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/Chapter.html
index 135b830..c75379e 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/Chapter.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/Chapter.html
@@ -42,7 +42,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="Chapter"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="chapter" id="Chapter">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Previous section 
in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Up section"> Up 
</a>]</td>
@@ -80,6 +81,7 @@ and titlepage, and various wrong index entries.
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/Copying-and-indices.html
 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/Copying-and-indices.html
index c15e6ac..41da972 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/Copying-and-indices.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/Copying-and-indices.html
@@ -124,6 +124,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -138,7 +139,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_no_insertcopying_abt.html#SEC_About" title="About 
(help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/index.html
 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/index.html
index 3a7646e..ca29274 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/index.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_insertcopying_html/index.html
@@ -97,6 +97,7 @@ domain<a id="DOCF1" 
href="index_special_region_no_insertcopying_fot.html#FOOT1">
 <td valign="middle" align="left">[<a 
href="index_special_region_no_insertcopying_abt.html#SEC_About" title="About 
(help)"> ? </a>]</td>
 </tr></table>
 <span id="Top-1"></span><h1 class="top">Top</h1>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -106,7 +107,6 @@ domain<a id="DOCF1" 
href="index_special_region_no_insertcopying_fot.html#FOOT1">
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_no_insertcopying_abt.html#SEC_About" title="About 
(help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_region/Chapter.html 
b/tp/tests/indices/res_parser/index_special_region_no_region/Chapter.html
index 548f109..5f0d333 100644
--- a/tp/tests/indices/res_parser/index_special_region_no_region/Chapter.html
+++ b/tp/tests/indices/res_parser/index_special_region_no_region/Chapter.html
@@ -42,7 +42,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="Chapter"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="chapter" id="Chapter">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Previous section 
in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Up section"> Up 
</a>]</td>
@@ -80,6 +81,7 @@ and titlepage, and various wrong index entries.
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_region/Copying-and-indices.html
 
b/tp/tests/indices/res_parser/index_special_region_no_region/Copying-and-indices.html
index 9637642..d7ef2ac 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_region/Copying-and-indices.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_region/Copying-and-indices.html
@@ -124,6 +124,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -138,7 +139,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_no_region_abt.html#SEC_About" title="About (help)"> 
? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_region/index.html 
b/tp/tests/indices/res_parser/index_special_region_no_region/index.html
index da41af6..cf58996 100644
--- a/tp/tests/indices/res_parser/index_special_region_no_region/index.html
+++ b/tp/tests/indices/res_parser/index_special_region_no_region/index.html
@@ -56,6 +56,7 @@ ul.no-bullet {list-style: none}
 </tr></table>
 <span id="Top-1"></span><h1 class="top">Top</h1>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -65,7 +66,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_no_region_abt.html#SEC_About" title="About (help)"> 
? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_region_html/Chapter.html 
b/tp/tests/indices/res_parser/index_special_region_no_region_html/Chapter.html
index 4111178..d06b2a6 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_region_html/Chapter.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_region_html/Chapter.html
@@ -42,7 +42,8 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<span id="Chapter"></span><table class="header" cellpadding="1" 
cellspacing="1" border="0">
+<div class="chapter" id="Chapter">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Previous section 
in reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="index.html" title="Up section"> Up 
</a>]</td>
@@ -80,6 +81,7 @@ and titlepage, and various wrong index entries.
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_region_html/Copying-and-indices.html
 
b/tp/tests/indices/res_parser/index_special_region_no_region_html/Copying-and-indices.html
index 1ec903b..f31ed23 100644
--- 
a/tp/tests/indices/res_parser/index_special_region_no_region_html/Copying-and-indices.html
+++ 
b/tp/tests/indices/res_parser/index_special_region_no_region_html/Copying-and-indices.html
@@ -124,6 +124,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="Chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -138,7 +139,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_no_region_abt.html#SEC_About" title="About (help)"> 
? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_special_region_no_region_html/index.html 
b/tp/tests/indices/res_parser/index_special_region_no_region_html/index.html
index 0bb4406..3bb3313 100644
--- a/tp/tests/indices/res_parser/index_special_region_no_region_html/index.html
+++ b/tp/tests/indices/res_parser/index_special_region_no_region_html/index.html
@@ -98,6 +98,7 @@ domain<a id="DOCF1" 
href="index_special_region_no_region_fot.html#FOOT1"><sup>2<
 </tr></table>
 <span id="Top-1"></span><h1 class="top">Top</h1>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -107,7 +108,6 @@ domain<a id="DOCF1" 
href="index_special_region_no_region_fot.html#FOOT1"><sup>2<
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="index_special_region_no_region_abt.html#SEC_About" title="About (help)"> 
? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/indices/res_parser/index_table/index.html 
b/tp/tests/indices/res_parser/index_table/index.html
index 7b90bdf..6c87997 100644
--- a/tp/tests/indices/res_parser/index_table/index.html
+++ b/tp/tests/indices/res_parser/index_table/index.html
@@ -55,6 +55,7 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -64,7 +65,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="node-with-printindex.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_table_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/indices/res_parser/index_table/indices-refs.html 
b/tp/tests/indices/res_parser/index_table/indices-refs.html
index 4e00d4a..5308542 100644
--- a/tp/tests/indices/res_parser/index_table/indices-refs.html
+++ b/tp/tests/indices/res_parser/index_table/indices-refs.html
@@ -531,6 +531,8 @@ ul.no-bullet {list-style: none}
 
 <p>A section following the indices.
 </p>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#indices-refs" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -545,8 +547,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="node-with-printindex.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_table_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/index_table/node-with-ftable-and-vtable.html 
b/tp/tests/indices/res_parser/index_table/node-with-ftable-and-vtable.html
index f5f93a0..7407459 100644
--- a/tp/tests/indices/res_parser/index_table/node-with-ftable-and-vtable.html
+++ b/tp/tests/indices/res_parser/index_table/node-with-ftable-and-vtable.html
@@ -79,6 +79,7 @@ ul.no-bullet {list-style: none}
 </p></dd>
 </dl>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -93,7 +94,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="node-with-printindex.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_table_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/indices/res_parser/index_table/node-with-printindex.html 
b/tp/tests/indices/res_parser/index_table/node-with-printindex.html
index 730ae5e..8341fe4 100644
--- a/tp/tests/indices/res_parser/index_table/node-with-printindex.html
+++ b/tp/tests/indices/res_parser/index_table/node-with-printindex.html
@@ -414,6 +414,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a 
href="node-with-ftable-and-vtable.html" title="Beginning of this chapter or 
previous chapter"> &lt;&lt; </a>]</td>
@@ -428,7 +429,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="#node-with-printindex" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="index_table_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter/chapter.html
 
b/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter/chapter.html
index f17aab5..e1d36f0 100644
--- 
a/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter/chapter.html
+++ 
b/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter/chapter.html
@@ -126,6 +126,7 @@ ul.no-bullet {list-style: none}
 <span id="node-in-chapter"></span>
 <span id="index-node-in-chapter"></span>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="index.html" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -140,7 +141,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="nodes_before_top_and_sections_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter/index.html
 
b/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter/index.html
index 01bd25d..aac83ae 100644
--- 
a/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter/index.html
+++ 
b/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter/index.html
@@ -715,6 +715,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -724,7 +725,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="nodes_before_top_and_sections_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter_nodes/chapter.html
 
b/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter_nodes/chapter.html
index e5b3012..6c16db1 100644
--- 
a/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter_nodes/chapter.html
+++ 
b/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter_nodes/chapter.html
@@ -143,6 +143,7 @@ ul.no-bullet {list-style: none}
 
 <span id="index-node-in-chapter"></span>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#chapter" title="Beginning of 
this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -157,7 +158,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a 
href="first-before-top.html#first-before-top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="nodes_before_top_and_sections_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter_nodes/index.html
 
b/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter_nodes/index.html
index 1fdfdae..5695e85 100644
--- 
a/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter_nodes/index.html
+++ 
b/tp/tests/indices/res_parser/nodes_before_top_and_sections_html_chapter_nodes/index.html
@@ -559,6 +559,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#Top" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -573,7 +574,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a 
href="first-before-top.html#first-before-top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a 
href="nodes_before_top_and_sections_abt.html#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/indices/res_parser/printindex_between_part_chapter/printindex_between_part_chapter.html
 
b/tp/tests/indices/res_parser/printindex_between_part_chapter/printindex_between_part_chapter.html
index e574b24..303679d 100644
--- 
a/tp/tests/indices/res_parser/printindex_between_part_chapter/printindex_between_part_chapter.html
+++ 
b/tp/tests/indices/res_parser/printindex_between_part_chapter/printindex_between_part_chapter.html
@@ -74,7 +74,9 @@ ul.no-bullet {list-style: none}
 </table>
 
 <hr size="6">
-<span id="Part-1"></span><table class="header" cellpadding="1" cellspacing="1" 
border="0">
+</div>
+<div class="part" id="Part-1">
+<table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#Top" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Previous section in 
reading order"> &lt; </a>]</td>
 <td valign="middle" align="left">[<a href="#Top" title="Up section"> Up 
</a>]</td>
diff --git 
a/tp/tests/indices/res_parser_info/index_special_region_html/Copying-and-indices.html
 
b/tp/tests/indices/res_parser_info/index_special_region_html/Copying-and-indices.html
index a6bc82c..045a80c 100644
--- 
a/tp/tests/indices/res_parser_info/index_special_region_html/Copying-and-indices.html
+++ 
b/tp/tests/indices/res_parser_info/index_special_region_html/Copying-and-indices.html
@@ -154,6 +154,7 @@ domain<a id="DOCF1_2" href="#FOOT1_2"><sup>2</sup></a>.
  &nbsp; 
 </td></tr></table>
 
+</div>
 <div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
@@ -169,7 +170,6 @@ domain is something you should allready know
 <p>
 Previous: <a href="index.html" accesskey="p" rel="prev">Top</a>, Up: <a 
href="index.html" accesskey="u" rel="up">Top</a> &nbsp; [<a 
href="index.html#SEC_Contents" title="Table of contents" 
rel="contents">Contents</a>][<a href="index.html" title="Index" 
rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/index_special_region_html/index.html 
b/tp/tests/indices/res_parser_info/index_special_region_html/index.html
index 242dcea..ac5b109 100644
--- a/tp/tests/indices/res_parser_info/index_special_region_html/index.html
+++ b/tp/tests/indices/res_parser_info/index_special_region_html/index.html
@@ -66,7 +66,8 @@ Next: <a href="Copying-and-indices.html" accesskey="n" 
rel="next">Copying and in
 </ul>
 </div>
 </div>
-<span id="Chapter"></span><h2 class="chapter">1 Chapter</h2>
+<div class="chapter" id="Chapter">
+<h2 class="chapter">1 Chapter</h2>
 
 
 <span id="index-copying-Copying-this-document"></span>
@@ -121,6 +122,8 @@ and titlepage, and various wrong index entries.
 </dl>
 
 
+</div>
+</div>
 <div class="footnote">
 <hr>
 <h4 class="footnotes-heading">Footnotes</h4>
@@ -136,7 +139,6 @@ domain is something you should allready know
 <p>
 Next: <a href="Copying-and-indices.html" accesskey="n" rel="next">Copying and 
indices</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" 
rel="contents">Contents</a>][<a href="#Top" title="Index" 
rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/index_special_region_no_insertcopying_html/Copying-and-indices.html
 
b/tp/tests/indices/res_parser_info/index_special_region_no_insertcopying_html/Copying-and-indices.html
index d5148b5..49faa29 100644
--- 
a/tp/tests/indices/res_parser_info/index_special_region_no_insertcopying_html/Copying-and-indices.html
+++ 
b/tp/tests/indices/res_parser_info/index_special_region_no_insertcopying_html/Copying-and-indices.html
@@ -117,12 +117,12 @@ Previous: <a href="index.html" accesskey="p" 
rel="prev">Top</a>, Up: <a href="in
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <div class="header">
 <p>
 Previous: <a href="index.html" accesskey="p" rel="prev">Top</a>, Up: <a 
href="index.html" accesskey="u" rel="up">Top</a> &nbsp; [<a 
href="index.html#SEC_Contents" title="Table of contents" 
rel="contents">Contents</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/index_special_region_no_insertcopying_html/index.html
 
b/tp/tests/indices/res_parser_info/index_special_region_no_insertcopying_html/index.html
index 66a29be..08cee4f 100644
--- 
a/tp/tests/indices/res_parser_info/index_special_region_no_insertcopying_html/index.html
+++ 
b/tp/tests/indices/res_parser_info/index_special_region_no_insertcopying_html/index.html
@@ -65,7 +65,8 @@ Next: <a href="Copying-and-indices.html" accesskey="n" 
rel="next">Copying and in
 </ul>
 </div>
 </div>
-<span id="Chapter"></span><h2 class="chapter">1 Chapter</h2>
+<div class="chapter" id="Chapter">
+<h2 class="chapter">1 Chapter</h2>
 
 
 <p>This test demonstrates @anchor and indices in @copying
@@ -84,12 +85,13 @@ and titlepage, and various wrong index entries.
 </dl>
 
 
+</div>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="Copying-and-indices.html" accesskey="n" rel="next">Copying and 
indices</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" 
rel="contents">Contents</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/index_special_region_no_region_html/Copying-and-indices.html
 
b/tp/tests/indices/res_parser_info/index_special_region_no_region_html/Copying-and-indices.html
index d5148b5..49faa29 100644
--- 
a/tp/tests/indices/res_parser_info/index_special_region_no_region_html/Copying-and-indices.html
+++ 
b/tp/tests/indices/res_parser_info/index_special_region_no_region_html/Copying-and-indices.html
@@ -117,12 +117,12 @@ Previous: <a href="index.html" accesskey="p" 
rel="prev">Top</a>, Up: <a href="in
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <div class="header">
 <p>
 Previous: <a href="index.html" accesskey="p" rel="prev">Top</a>, Up: <a 
href="index.html" accesskey="u" rel="up">Top</a> &nbsp; [<a 
href="index.html#SEC_Contents" title="Table of contents" 
rel="contents">Contents</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/index_special_region_no_region_html/index.html
 
b/tp/tests/indices/res_parser_info/index_special_region_no_region_html/index.html
index 09eaca2..0964da1 100644
--- 
a/tp/tests/indices/res_parser_info/index_special_region_no_region_html/index.html
+++ 
b/tp/tests/indices/res_parser_info/index_special_region_no_region_html/index.html
@@ -66,7 +66,8 @@ Next: <a href="Copying-and-indices.html" accesskey="n" 
rel="next">Copying and in
 </ul>
 </div>
 </div>
-<span id="Chapter"></span><h2 class="chapter">1 Chapter</h2>
+<div class="chapter" id="Chapter">
+<h2 class="chapter">1 Chapter</h2>
 
 
 <p>This test demonstrates @anchor and indices in @copying
@@ -85,12 +86,13 @@ and titlepage, and various wrong index entries.
 </dl>
 
 
+</div>
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="Copying-and-indices.html" accesskey="n" rel="next">Copying and 
indices</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" 
rel="contents">Contents</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter/chapter.html
 
b/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter/chapter.html
index 7951e6b..aa75322 100644
--- 
a/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter/chapter.html
+++ 
b/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter/chapter.html
@@ -125,12 +125,12 @@ Previous: <a href="#chapter" accesskey="p" rel="prev">A 
chapter</a>, Up: <a href
 
 <span id="index-node-in-chapter"></span>
 
+</div>
 <hr>
 <div class="header">
 <p>
 Previous: <a href="#chapter" accesskey="p" rel="prev">A chapter</a>, Up: <a 
href="index.html#Top" accesskey="u" rel="up">top section</a> &nbsp; [<a 
href="first-before-top.html#first-before-top" title="Index" 
rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter/index.html
 
b/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter/index.html
index 2706266..1f3db08 100644
--- 
a/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter/index.html
+++ 
b/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter/index.html
@@ -499,12 +499,12 @@ Next: <a href="#another" accesskey="n" 
rel="next">another</a>, Up: <a href="#sec
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="#another" accesskey="n" rel="next">another</a>, Up: <a 
href="#second" accesskey="u" rel="up">second</a> &nbsp; [<a 
href="first-before-top.html#first-before-top" title="Index" 
rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter_nodes/chapter.html
 
b/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter_nodes/chapter.html
index 7951e6b..aa75322 100644
--- 
a/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter_nodes/chapter.html
+++ 
b/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter_nodes/chapter.html
@@ -125,12 +125,12 @@ Previous: <a href="#chapter" accesskey="p" rel="prev">A 
chapter</a>, Up: <a href
 
 <span id="index-node-in-chapter"></span>
 
+</div>
 <hr>
 <div class="header">
 <p>
 Previous: <a href="#chapter" accesskey="p" rel="prev">A chapter</a>, Up: <a 
href="index.html#Top" accesskey="u" rel="up">top section</a> &nbsp; [<a 
href="first-before-top.html#first-before-top" title="Index" 
rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git 
a/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter_nodes/index.html
 
b/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter_nodes/index.html
index 2706266..1f3db08 100644
--- 
a/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter_nodes/index.html
+++ 
b/tp/tests/indices/res_parser_info/nodes_before_top_and_sections_html_chapter_nodes/index.html
@@ -499,12 +499,12 @@ Next: <a href="#another" accesskey="n" 
rel="next">another</a>, Up: <a href="#sec
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <div class="header">
 <p>
 Next: <a href="#another" accesskey="n" rel="next">another</a>, Up: <a 
href="#second" accesskey="u" rel="up">second</a> &nbsp; [<a 
href="first-before-top.html#first-before-top" title="Index" 
rel="index">Index</a>]</p>
 </div>
-</div>
 
 
 
diff --git a/tp/tests/layout/res_parser/formatting_chm/chapter.html 
b/tp/tests/layout/res_parser/formatting_chm/chapter.html
index 3d5d5f3..b034d45 100644
--- a/tp/tests/layout/res_parser/formatting_chm/chapter.html
+++ b/tp/tests/layout/res_parser/formatting_chm/chapter.html
@@ -661,6 +661,7 @@ ul.no-bullet {list-style: none}
 <p><a id="DOCF9" href="#FOOT9"><sup>11</sup></a>
 </p>
 
+</div>
 <div class="footnote">
 <h3 class="footnotes-heading">Footnotes</h3>
 
diff --git a/tp/tests/layout/res_parser/formatting_chm/chapter2.html 
b/tp/tests/layout/res_parser/formatting_chm/chapter2.html
index f0636f0..a9c147d 100644
--- a/tp/tests/layout/res_parser/formatting_chm/chapter2.html
+++ b/tp/tests/layout/res_parser/formatting_chm/chapter2.html
@@ -655,10 +655,6 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-</div>
-</div>
-</div>
-</div>
 <div class="centerchap" id="chapter2">
 <span id="chapter-2"></span><h1 class="centerchap" align="center">chapter 
2</h1>
 
@@ -983,6 +979,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <p>
 
 </p>
diff --git a/tp/tests/layout/res_parser/formatting_chm/formatting.html 
b/tp/tests/layout/res_parser/formatting_chm/formatting.html
index e192d22..6ccb42f 100644
--- a/tp/tests/layout/res_parser/formatting_chm/formatting.html
+++ b/tp/tests/layout/res_parser/formatting_chm/formatting.html
@@ -4968,6 +4968,7 @@ Invalid use of @':
 
 
 
+</div>
 <div class="footnote">
 <h3 class="footnotes-heading">Footnotes</h3>
 
diff --git a/tp/tests/layout/res_parser/formatting_chm/formatting_toc.html 
b/tp/tests/layout/res_parser/formatting_chm/formatting_toc.html
index 216fbd8..82bd43d 100644
--- a/tp/tests/layout/res_parser/formatting_chm/formatting_toc.html
+++ b/tp/tests/layout/res_parser/formatting_chm/formatting_toc.html
@@ -655,8 +655,6 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-</div>
-</div>
 <div class="Contents_element" id="SEC_Contents">
 <h1 class="contents-heading">Table of Contents</h1>
 
diff --git 
a/tp/tests/layout/res_parser/formatting_chm/s_002d_002dect_002cion.html 
b/tp/tests/layout/res_parser/formatting_chm/s_002d_002dect_002cion.html
index 76e6531..b3196ab 100644
--- a/tp/tests/layout/res_parser/formatting_chm/s_002d_002dect_002cion.html
+++ b/tp/tests/layout/res_parser/formatting_chm/s_002d_002dect_002cion.html
@@ -659,6 +659,7 @@ ul.no-bullet {list-style: none}
 <span id="A-section"></span><h2 class="section">1.1 A section</h2>
 
 
+</div>
 <p>
 
 </p>
diff --git a/tp/tests/layout/res_parser/formatting_chm/subsection.html 
b/tp/tests/layout/res_parser/formatting_chm/subsection.html
index 604f74b..cb1c27c 100644
--- a/tp/tests/layout/res_parser/formatting_chm/subsection.html
+++ b/tp/tests/layout/res_parser/formatting_chm/subsection.html
@@ -660,6 +660,7 @@ ul.no-bullet {list-style: none}
 
 
 <span id="anchor"></span>
+</div>
 <p>
 
 </p>
diff --git 
a/tp/tests/layout/res_parser/formatting_chm/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
 
b/tp/tests/layout/res_parser/formatting_chm/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
index 177df39..3531a89 100644
--- 
a/tp/tests/layout/res_parser/formatting_chm/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
+++ 
b/tp/tests/layout/res_parser/formatting_chm/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
@@ -658,6 +658,7 @@ ul.no-bullet {list-style: none}
 <div class="subsubsection" 
id="subsubsection-_0060_0060simple_002ddouble_002d_002d">
 <span id="subsubsection-_0060_0060simple_002ddouble_002d_002d-1"></span><h4 
class="subsubsection">1.1.1.1 subsubsection &ldquo;simple-double&ndash;</h4>
 
+</div>
 <p>
 
 </p>
diff --git 
a/tp/tests/layout/res_parser/formatting_chm/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
 
b/tp/tests/layout/res_parser/formatting_chm/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
index a2abc60..95a0079 100644
--- 
a/tp/tests/layout/res_parser/formatting_chm/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
+++ 
b/tp/tests/layout/res_parser/formatting_chm/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
@@ -655,10 +655,10 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-</div>
 <div class="subsubsection" 
id="subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027">
 <span id="three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027"></span><h4 
class="subsubsection">1.1.1.2 three&mdash;four&mdash;-&rdquo;</h4>
 
+</div>
 <p>
 
 </p>
diff --git a/tp/tests/layout/res_parser/formatting_exotic/chapter.html 
b/tp/tests/layout/res_parser/formatting_exotic/chapter.html
index 39c4a81..9881887 100644
--- a/tp/tests/layout/res_parser/formatting_exotic/chapter.html
+++ b/tp/tests/layout/res_parser/formatting_exotic/chapter.html
@@ -677,6 +677,7 @@ ul.no-bullet {list-style: none}
 <p><a id="DOCF9" href="#FOOT9"><sup>7</sup></a>
 </p>
 
+</div>
 <div class="footnote">
 <hr>
 <h3 class="footnotes-heading">Footnotes</h3>
@@ -692,7 +693,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a 
href="s_002d_002dect_002cion.html#s_002d_002dect_002cion" title="Next section 
in reading order"> &gt; </a>]</td>
 <td valign="middle" align="left">[<a href="chapter2.html" title="Next 
chapter"> &gt;&gt; </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_exotic/chapter2.html 
b/tp/tests/layout/res_parser/formatting_exotic/chapter2.html
index 9332908..b5f6338 100644
--- a/tp/tests/layout/res_parser/formatting_exotic/chapter2.html
+++ b/tp/tests/layout/res_parser/formatting_exotic/chapter2.html
@@ -995,6 +995,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -1003,7 +1004,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[ &gt; ]</td>
 <td valign="middle" align="left">[ &gt;&gt; ]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_exotic/index.html 
b/tp/tests/layout/res_parser/formatting_exotic/index.html
index 567e4f8..b9a93fc 100644
--- a/tp/tests/layout/res_parser/formatting_exotic/index.html
+++ b/tp/tests/layout/res_parser/formatting_exotic/index.html
@@ -3461,6 +3461,7 @@ Invalid use of @':
 
 
 
+</div>
 <div class="footnote">
 <hr>
 <h3 class="footnotes-heading">Footnotes</h3>
@@ -3487,7 +3488,6 @@ Invalid use of @':
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="formatting_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/formatting_exotic/s_002d_002dect_002cion.html 
b/tp/tests/layout/res_parser/formatting_exotic/s_002d_002dect_002cion.html
index 5c5f7b1..f8fdccb 100644
--- a/tp/tests/layout/res_parser/formatting_exotic/s_002d_002dect_002cion.html
+++ b/tp/tests/layout/res_parser/formatting_exotic/s_002d_002dect_002cion.html
@@ -690,6 +690,9 @@ ul.no-bullet {list-style: none}
 <div class="subsubsection" 
id="subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027">
 <span id="three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027"></span><h4 
class="subsubsection"><a 
href="formatting_toc.html#toc-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027">three&mdash;four&mdash;-&rdquo;</a></h4>
 
+</div>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -698,9 +701,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="chapter2.html" title="Next section 
in reading order"> &gt; </a>]</td>
 <td valign="middle" align="left">[<a href="chapter2.html" title="Next 
chapter"> &gt;&gt; </a>]</td>
 </tr></table>
-</div>
-</div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_html_nodes/chapter.html 
b/tp/tests/layout/res_parser/formatting_html_nodes/chapter.html
index d301462..ef11988 100644
--- a/tp/tests/layout/res_parser/formatting_html_nodes/chapter.html
+++ b/tp/tests/layout/res_parser/formatting_html_nodes/chapter.html
@@ -688,8 +688,8 @@ Menu comment
 </pre></td></tr></table>
 </div>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_html_nodes/chapter2.html 
b/tp/tests/layout/res_parser/formatting_html_nodes/chapter2.html
index 974bf16..118ca4d 100644
--- a/tp/tests/layout/res_parser/formatting_html_nodes/chapter2.html
+++ b/tp/tests/layout/res_parser/formatting_html_nodes/chapter2.html
@@ -995,6 +995,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -1011,7 +1012,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="formatting_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_html_nodes/index.html 
b/tp/tests/layout/res_parser/formatting_html_nodes/index.html
index 61fab19..46454f4 100644
--- a/tp/tests/layout/res_parser/formatting_html_nodes/index.html
+++ b/tp/tests/layout/res_parser/formatting_html_nodes/index.html
@@ -4986,6 +4986,7 @@ Invalid use of @':
 
 
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -4995,7 +4996,6 @@ Invalid use of @':
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="formatting_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/formatting_html_nodes/s_002d_002dect_002cion.html 
b/tp/tests/layout/res_parser/formatting_html_nodes/s_002d_002dect_002cion.html
index 5d6f6df..230186b 100644
--- 
a/tp/tests/layout/res_parser/formatting_html_nodes/s_002d_002dect_002cion.html
+++ 
b/tp/tests/layout/res_parser/formatting_html_nodes/s_002d_002dect_002cion.html
@@ -687,8 +687,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_html_nodes/subsection.html 
b/tp/tests/layout/res_parser/formatting_html_nodes/subsection.html
index ac17af1..38bc819 100644
--- a/tp/tests/layout/res_parser/formatting_html_nodes/subsection.html
+++ b/tp/tests/layout/res_parser/formatting_html_nodes/subsection.html
@@ -682,8 +682,8 @@ ul.no-bullet {list-style: none}
 </table>
 
 <span id="anchor"></span>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/formatting_html_nodes/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
 
b/tp/tests/layout/res_parser/formatting_html_nodes/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
index 7d239b8..a028ed3 100644
--- 
a/tp/tests/layout/res_parser/formatting_html_nodes/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
+++ 
b/tp/tests/layout/res_parser/formatting_html_nodes/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
@@ -674,8 +674,8 @@ ul.no-bullet {list-style: none}
 <hr>
 <span id="subsubsection-_0060_0060simple_002ddouble_002d_002d-1"></span><h4 
class="subsubsection">1.1.1.1 subsubsection &ldquo;simple-double&ndash;</h4>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/formatting_html_nodes/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
 
b/tp/tests/layout/res_parser/formatting_html_nodes/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
index 5efc00f..8230b1a 100644
--- 
a/tp/tests/layout/res_parser/formatting_html_nodes/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
+++ 
b/tp/tests/layout/res_parser/formatting_html_nodes/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
@@ -674,8 +674,8 @@ ul.no-bullet {list-style: none}
 <hr>
 <span id="three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027"></span><h4 
class="subsubsection">1.1.1.2 three&mdash;four&mdash;-&rdquo;</h4>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_nodes/chapter.html 
b/tp/tests/layout/res_parser/formatting_nodes/chapter.html
index d301462..ef11988 100644
--- a/tp/tests/layout/res_parser/formatting_nodes/chapter.html
+++ b/tp/tests/layout/res_parser/formatting_nodes/chapter.html
@@ -688,8 +688,8 @@ Menu comment
 </pre></td></tr></table>
 </div>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_nodes/chapter2.html 
b/tp/tests/layout/res_parser/formatting_nodes/chapter2.html
index 974bf16..118ca4d 100644
--- a/tp/tests/layout/res_parser/formatting_nodes/chapter2.html
+++ b/tp/tests/layout/res_parser/formatting_nodes/chapter2.html
@@ -995,6 +995,7 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="chapter.html" title="Beginning 
of this chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -1011,7 +1012,6 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[<a href="index.html" 
title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="formatting_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_nodes/index.html 
b/tp/tests/layout/res_parser/formatting_nodes/index.html
index 61fab19..46454f4 100644
--- a/tp/tests/layout/res_parser/formatting_nodes/index.html
+++ b/tp/tests/layout/res_parser/formatting_nodes/index.html
@@ -4986,6 +4986,7 @@ Invalid use of @':
 
 
 
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[ &lt; ]</td>
@@ -4995,7 +4996,6 @@ Invalid use of @':
 <td valign="middle" align="left">[<a href="#Top" title="Index">Index</a>]</td>
 <td valign="middle" align="left">[<a href="formatting_abt.html#SEC_About" 
title="About (help)"> ? </a>]</td>
 </tr></table>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/formatting_nodes/s_002d_002dect_002cion.html 
b/tp/tests/layout/res_parser/formatting_nodes/s_002d_002dect_002cion.html
index 5d6f6df..230186b 100644
--- a/tp/tests/layout/res_parser/formatting_nodes/s_002d_002dect_002cion.html
+++ b/tp/tests/layout/res_parser/formatting_nodes/s_002d_002dect_002cion.html
@@ -687,8 +687,8 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/layout/res_parser/formatting_nodes/subsection.html 
b/tp/tests/layout/res_parser/formatting_nodes/subsection.html
index ac17af1..38bc819 100644
--- a/tp/tests/layout/res_parser/formatting_nodes/subsection.html
+++ b/tp/tests/layout/res_parser/formatting_nodes/subsection.html
@@ -682,8 +682,8 @@ ul.no-bullet {list-style: none}
 </table>
 
 <span id="anchor"></span>
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/formatting_nodes/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
 
b/tp/tests/layout/res_parser/formatting_nodes/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
index 7d239b8..a028ed3 100644
--- 
a/tp/tests/layout/res_parser/formatting_nodes/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
+++ 
b/tp/tests/layout/res_parser/formatting_nodes/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
@@ -674,8 +674,8 @@ ul.no-bullet {list-style: none}
 <hr>
 <span id="subsubsection-_0060_0060simple_002ddouble_002d_002d-1"></span><h4 
class="subsubsection">1.1.1.1 subsubsection &ldquo;simple-double&ndash;</h4>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/formatting_nodes/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
 
b/tp/tests/layout/res_parser/formatting_nodes/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
index 5efc00f..8230b1a 100644
--- 
a/tp/tests/layout/res_parser/formatting_nodes/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
+++ 
b/tp/tests/layout/res_parser/formatting_nodes/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
@@ -674,8 +674,8 @@ ul.no-bullet {list-style: none}
 <hr>
 <span id="three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027"></span><h4 
class="subsubsection">1.1.1.2 three&mdash;four&mdash;-&rdquo;</h4>
 
-<hr>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/navigation_test_misc_file_collision/chapter.html 
b/tp/tests/layout/res_parser/navigation_test_misc_file_collision/chapter.html
index 716dcff..30f1ad6 100644
--- 
a/tp/tests/layout/res_parser/navigation_test_misc_file_collision/chapter.html
+++ 
b/tp/tests/layout/res_parser/navigation_test_misc_file_collision/chapter.html
@@ -60,9 +60,9 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table>
 
-<hr>
 </div>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git 
a/tp/tests/layout/res_parser/navigation_test_misc_file_collision/subsection.html
 
b/tp/tests/layout/res_parser/navigation_test_misc_file_collision/subsection.html
index 566c542..1f40068 100644
--- 
a/tp/tests/layout/res_parser/navigation_test_misc_file_collision/subsection.html
+++ 
b/tp/tests/layout/res_parser/navigation_test_misc_file_collision/subsection.html
@@ -56,9 +56,9 @@ ul.no-bullet {list-style: none}
 <span id="Sub-section-in-section"></span><h3 class="subsection">1.1.1 Sub 
section in section</h3>
 
 
-<hr>
 </div>
 </div>
+<hr>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/many_input_files/tex_l2h_res/tex.html 
b/tp/tests/many_input_files/tex_l2h_res/tex.html
index e61c5e0..8dcf329 100644
--- a/tp/tests/many_input_files/tex_l2h_res/tex.html
+++ b/tp/tests/many_input_files/tex_l2h_res/tex.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -35,8 +37,7 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
 <p>Now tex on the same line 
 <P>
@@ -123,8 +124,7 @@ Here some <!-- MATH
 $">
 </DIV>
 
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/many_input_files/tex_l2h_res/tex_complex.html 
b/tp/tests/many_input_files/tex_l2h_res/tex_complex.html
index fd387a6..3ecebdc 100644
--- a/tp/tests/many_input_files/tex_l2h_res/tex_complex.html
+++ b/tp/tests/many_input_files/tex_l2h_res/tex_complex.html
@@ -14,6 +14,8 @@ Some (I-D) \varphi(t) math. -->
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -64,8 +66,7 @@ $">
 
 
 <div class="top" id="Top">
-<div class="node" id="The-title">
-<h1 class="top">The title</h1>
+<span id="The-title"></span><h1 class="top">The title</h1>
 
 <DIV CLASS="displaymath">
 <!-- MATH
@@ -109,7 +110,7 @@ $">
 </p>
 <p>Now there is a footnote<a id="DOCF1" href="#FOOT1"><sup>1</sup></a>
 </p>
-</div><div class="footnote">
+<div class="footnote">
 <hr>
 <h3 class="footnotes-heading">Footnotes</h3>
 
@@ -137,7 +138,6 @@ $">
 </p>
 </div>
 <hr></div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/many_input_files/tex_t4ht_res/tex.html 
b/tp/tests/many_input_files/tex_t4ht_res/tex.html
index 152266c..4fcfb10 100644
--- a/tp/tests/many_input_files/tex_t4ht_res/tex.html
+++ b/tp/tests/many_input_files/tex_t4ht_res/tex.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 @import "tex_tex4ht_displaymath.css";
@@ -39,8 +41,7 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
 <p>Now tex on the same line 
 <!--l. 5--><p class="indent" >
@@ -114,8 +115,7 @@ src="tex_tex4ht_displaymath0x.png" alt="                    
    (      )2
 " class="math-display" ></div>
 <!--l. 7--><p class="indent" >     
 
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/many_input_files/tex_t4ht_res/tex_complex.html 
b/tp/tests/many_input_files/tex_t4ht_res/tex_complex.html
index f3fff0a..c163c42 100644
--- a/tp/tests/many_input_files/tex_t4ht_res/tex_complex.html
+++ b/tp/tests/many_input_files/tex_t4ht_res/tex_complex.html
@@ -14,6 +14,8 @@ Some (I-D) \varphi(t) math. -->
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 @import "tex_complex_tex4ht_math.css";
@@ -60,8 +62,7 @@ class="cmmi-10">t</span>)  math.
 
 
 <div class="top" id="Top">
-<div class="node" id="The-title">
-<h1 class="top">The title</h1>
+<span id="The-title"></span><h1 class="top">The title</h1>
 
 
     <div class="math-display" >
@@ -92,7 +93,7 @@ class="cmmi-7">t</span></sup> .
 </p>
 <p>Now there is a footnote<a id="DOCF1" href="#FOOT1"><sup>1</sup></a>
 </p>
-</div><div class="footnote">
+<div class="footnote">
 <hr>
 <h3 class="footnotes-heading">Footnotes</h3>
 
@@ -111,7 +112,6 @@ class="cmmi-7">&#x03D5;</span></sup> .
 </p>
 </div>
 <hr></div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/block_EOL_tex/block_EOL.html 
b/tp/tests/tex_html/res_parser/block_EOL_tex/block_EOL.html
index 39614b4..87ffd4a 100644
--- a/tp/tests/tex_html/res_parser/block_EOL_tex/block_EOL.html
+++ b/tp/tests/tex_html/res_parser/block_EOL_tex/block_EOL.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -36,12 +38,10 @@ ul.no-bullet {list-style: none}
 <body lang="en">
 
 <div class="top" id="Top">
-<div class="node" id="Test-for-end-of-lines-and-block-commands">
-<h1 class="top">Test for end of lines and block commands</h1>
+<span id="Test-for-end-of-lines-and-block-commands"></span><h1 
class="top">Test for end of lines and block commands</h1>
+
+<span id="html"></span><h2 class="heading">html</h2>
 
-<div class="heading" id="html">
-<h2 class="heading">html</h2>
-</div>
 Surrounded by empty lines.
 
 <p>Block commands on a line
@@ -64,9 +64,8 @@ end commands on a line.
 </p>
 <p>Before the opening command in block
 </p>
-<div class="heading" id="tex">
-<h2 class="heading">tex</h2>
-</div>
+<span id="tex"></span><h2 class="heading">tex</h2>
+
 Surrounded by empty lines.
 
 <p>Block commands on a line
@@ -84,9 +83,8 @@ end commands on a line.
 <p>Before the opening command in block
 </p>
 
-<div class="heading" id="verbatim">
-<h2 class="heading">verbatim</h2>
-</div>
+<span id="verbatim"></span><h2 class="heading">verbatim</h2>
+
 <pre class="verbatim">Surrounded by empty lines.
 </pre>
 <p>Block commands on a line
@@ -105,8 +103,7 @@ end commands on a line.
 <p>Before the opening command </p><pre class="verbatim">in block
 </pre><p>. A symbol after the closing command.
 </p>
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/formatting_singular/chapter.html 
b/tp/tests/tex_html/res_parser/formatting_singular/chapter.html
index c7e6242..cd3a16f 100644
--- a/tp/tests/tex_html/res_parser/formatting_singular/chapter.html
+++ b/tp/tests/tex_html/res_parser/formatting_singular/chapter.html
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -696,8 +698,7 @@ ul.no-bullet {list-style: none}
 </table>
 </td>
 <td align="left">
-<div class="node" id="chapter-1">
-<h1 class="chapter">1 chapter</h1>
+<span id="chapter-1"></span><h1 class="chapter">1 chapter</h1>
 
 <p><a id="DOCF9" href="sing_fot.htm#FOOT9"><sup>7</sup></a>
 </p>
@@ -713,9 +714,11 @@ Menu comment
 </pre></table></blockquote>
 </div>
 
-</div></td>
+</td>
 </tr>
 </table>
+</div>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">  <a href="index.htm"><img
diff --git a/tp/tests/tex_html/res_parser/formatting_singular/chapter2.html 
b/tp/tests/tex_html/res_parser/formatting_singular/chapter2.html
index c0e567e..80556f1 100644
--- a/tp/tests/tex_html/res_parser/formatting_singular/chapter2.html
+++ b/tp/tests/tex_html/res_parser/formatting_singular/chapter2.html
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -655,10 +657,6 @@ ul.no-bullet {list-style: none}
 
 <body lang="en"  background="../singular_images/Mybg.png">
 
-</div>
-</div>
-</div>
-</div>
 <div class="centerchap" id="chapter2">
 <table border="0" cellpadding="0" cellspacing="0">
 <tr valign="top">
@@ -700,8 +698,7 @@ ul.no-bullet {list-style: none}
 </table>
 </td>
 <td align="left">
-<div class="node" id="chapter-2">
-<h1 class="centerchap" align="center">chapter 2</h1>
+<span id="chapter-2"></span><h1 class="centerchap" align="center">chapter 
2</h1>
 
 <table><tr><th valign="top">Jump to: &nbsp; </th><td><a class="summary-letter" 
href="#chapter-2_cp_symbol-1"><b>&quot;</b></a>
  &nbsp; 
@@ -1024,9 +1021,10 @@ ul.no-bullet {list-style: none}
  &nbsp; 
 </td></tr></table>
 
-</div></td>
+</td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">  <a href="index.htm"><img
diff --git a/tp/tests/tex_html/res_parser/formatting_singular/index.htm 
b/tp/tests/tex_html/res_parser/formatting_singular/index.htm
index 7a61cde..de1fe2d 100644
--- a/tp/tests/tex_html/res_parser/formatting_singular/index.htm
+++ b/tp/tests/tex_html/res_parser/formatting_singular/index.htm
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -682,8 +684,7 @@ ul.no-bullet {list-style: none}
 </table>
 </td>
 <td align="left">
-<div class="node" id="Top-section">
-<h1 class="top">Top section</h1>
+<span id="Top-section"></span><h1 class="top">Top section</h1>
 
 <blockquote><table class="menu" border="0" cellspacing="0">
 <tr><td align="left" valign="top"><a href="chapter.html">1 
chapter</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top"></td></tr>
@@ -1370,21 +1371,16 @@ html ''
  &rdquo;
 
 
-<div class="majorheading" id="majorheading">
-<h1 class="majorheading">majorheading</h1>
-</div>
-<div class="chapheading" id="chapheading">
-<h1 class="chapheading">chapheading</h1>
-</div>
-<div class="heading" id="heading">
-<h2 class="heading">heading</h2>
-</div>
-<div class="subheading" id="subheading">
-<h3 class="subheading">subheading</h3>
-</div>
-<div class="subsubheading" id="subsubheading">
-<h4 class="subsubheading">subsubheading</h4>
-</div>
+<span id="majorheading"></span><h1 class="majorheading">majorheading</h1>
+
+<span id="chapheading"></span><h1 class="chapheading">chapheading</h1>
+
+<span id="heading"></span><h2 class="heading">heading</h2>
+
+<span id="subheading"></span><h3 class="subheading">subheading</h3>
+
+<span id="subsubheading"></span><h4 class="subsubheading">subsubheading</h4>
+
 
 <p><code>@acronym{--a,an accronym @comma{} @enddots{}}</code> <acronym 
title="an accronym , ...">&ndash;a</acronym> (an accronym , <small 
class="enddots">...</small>)
 <code>@abbr{@'E--. @comma{}A., @'Etude--@comma{} @b{Autonome} }</code> <abbr 
title="&Eacute;tude&ndash;, Autonome">&Eacute;&ndash;. ,A.</abbr> 
(&Eacute;tude&ndash;, <b>Autonome</b>)
@@ -2164,21 +2160,16 @@ html ''
  &rdquo;
 
 
-<div class="majorheading" id="majorheading-1">
-<h1 class="majorheading">majorheading</h1>
-</div>
-<div class="chapheading" id="chapheading-1">
-<h1 class="chapheading">chapheading</h1>
-</div>
-<div class="heading" id="heading-1">
-<h2 class="heading">heading</h2>
-</div>
-<div class="subheading" id="subheading-1">
-<h3 class="subheading">subheading</h3>
-</div>
-<div class="subsubheading" id="subsubheading-1">
-<h4 class="subsubheading">subsubheading</h4>
-</div>
+<span id="majorheading-1"></span><h1 class="majorheading">majorheading</h1>
+
+<span id="chapheading-1"></span><h1 class="chapheading">chapheading</h1>
+
+<span id="heading-1"></span><h2 class="heading">heading</h2>
+
+<span id="subheading-1"></span><h3 class="subheading">subheading</h3>
+
+<span id="subsubheading-1"></span><h4 class="subsubheading">subsubheading</h4>
+
 
 <p><code>@acronym{--a,an accronym @comma{} @enddots{}}</code> <acronym 
title="an accronym , ...">&ndash;a</acronym> (an accronym , <small 
class="enddots">...</small>)
 <code>@abbr{@'E--. @comma{}A., @'Etude--@comma{} @b{Autonome} }</code> <abbr 
title="&Eacute;tude&ndash;, Autonome">&Eacute;&ndash;. ,A.</abbr> 
(&Eacute;tude&ndash;, <b>Autonome</b>)
@@ -3042,25 +3033,20 @@ html ''
  &rdquo;
 
 
-</pre><div class="majorheading" id="majorheading-2">
-<strong>majorheading</strong>
-</div><pre class="example">
+</pre><span id="majorheading-2"></span><strong>majorheading</strong>
+<pre class="example">
 
-</pre><div class="chapheading" id="chapheading-2">
-<strong>chapheading</strong>
-</div><pre class="example">
+</pre><span id="chapheading-2"></span><strong>chapheading</strong>
+<pre class="example">
 
-</pre><div class="heading" id="heading-2">
-<strong>heading</strong>
-</div><pre class="example">
+</pre><span id="heading-2"></span><strong>heading</strong>
+<pre class="example">
 
-</pre><div class="subheading" id="subheading-2">
-<strong>subheading</strong>
-</div><pre class="example">
+</pre><span id="subheading-2"></span><strong>subheading</strong>
+<pre class="example">
 
-</pre><div class="subsubheading" id="subsubheading-2">
-<strong>subsubheading</strong>
-</div><pre class="example">
+</pre><span id="subsubheading-2"></span><strong>subsubheading</strong>
+<pre class="example">
 
 
 <code>@acronym{--a,an accronym @comma{} @enddots{}}</code> <acronym title="an 
accronym , ...">--a</acronym> (an accronym , ...)
@@ -3604,7 +3590,7 @@ Invalid use of @':
 
 
 
-</div><blockquote>
+<blockquote>
 <a href="sing_toc.htm#SEC_Contents">Table of Contents</a>
 <br>
 <a href="sing_abt.htm#SEC_About">About this document</a></blockquote></td>
diff --git 
a/tp/tests/tex_html/res_parser/formatting_singular/s_002d_002dect_002cion.html 
b/tp/tests/tex_html/res_parser/formatting_singular/s_002d_002dect_002cion.html
index d262cc0..a86e8d5 100644
--- 
a/tp/tests/tex_html/res_parser/formatting_singular/s_002d_002dect_002cion.html
+++ 
b/tp/tests/tex_html/res_parser/formatting_singular/s_002d_002dect_002cion.html
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -696,8 +698,7 @@ ul.no-bullet {list-style: none}
 </table>
 </td>
 <td align="left">
-<div class="node" id="A-section">
-<h2 class="section">1.1 A section</h2>
+<span id="A-section"></span><h2 class="section">1.1 A section</h2>
 
 <blockquote><table class="menu" border="0" cellspacing="0">
 <tr><td align="left" valign="top"><a href="subsection.html">1.1.1 
subsection</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
@@ -712,9 +713,10 @@ ul.no-bullet {list-style: none}
 </td></tr>
 </table></blockquote>
 
-</div></td>
+</td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">  <a href="index.htm"><img
diff --git a/tp/tests/tex_html/res_parser/formatting_singular/sing_abt.htm 
b/tp/tests/tex_html/res_parser/formatting_singular/sing_abt.htm
index 0fc5817..3b966a9 100644
--- a/tp/tests/tex_html/res_parser/formatting_singular/sing_abt.htm
+++ b/tp/tests/tex_html/res_parser/formatting_singular/sing_abt.htm
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
diff --git a/tp/tests/tex_html/res_parser/formatting_singular/sing_fot.htm 
b/tp/tests/tex_html/res_parser/formatting_singular/sing_fot.htm
index b3e5f43..9ead2c7 100644
--- a/tp/tests/tex_html/res_parser/formatting_singular/sing_fot.htm
+++ b/tp/tests/tex_html/res_parser/formatting_singular/sing_fot.htm
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -655,8 +657,6 @@ ul.no-bullet {list-style: none}
 
 <body lang="en"  background="../singular_images/Mybg.png">
 
-</div>
-</div>
 <div class="Footnotes_element" id="SEC_Foot">
 <table border="0" cellpadding="0" cellspacing="0">
 <tr valign="top">
diff --git a/tp/tests/tex_html/res_parser/formatting_singular/sing_ovr.htm 
b/tp/tests/tex_html/res_parser/formatting_singular/sing_ovr.htm
index 804960c..4a8123d 100644
--- a/tp/tests/tex_html/res_parser/formatting_singular/sing_ovr.htm
+++ b/tp/tests/tex_html/res_parser/formatting_singular/sing_ovr.htm
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
diff --git a/tp/tests/tex_html/res_parser/formatting_singular/sing_toc.htm 
b/tp/tests/tex_html/res_parser/formatting_singular/sing_toc.htm
index 713f4dd..5ad368d 100644
--- a/tp/tests/tex_html/res_parser/formatting_singular/sing_toc.htm
+++ b/tp/tests/tex_html/res_parser/formatting_singular/sing_toc.htm
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
diff --git a/tp/tests/tex_html/res_parser/formatting_singular/subsection.html 
b/tp/tests/tex_html/res_parser/formatting_singular/subsection.html
index d1af3ec..1dd247b 100644
--- a/tp/tests/tex_html/res_parser/formatting_singular/subsection.html
+++ b/tp/tests/tex_html/res_parser/formatting_singular/subsection.html
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -696,8 +698,7 @@ ul.no-bullet {list-style: none}
 </table>
 </td>
 <td align="left">
-<div class="node" id="subsection-1">
-<h3 class="subsection">1.1.1 subsection</h3>
+<span id="subsection-1"></span><h3 class="subsection">1.1.1 subsection</h3>
 
 <blockquote><table class="menu" border="0" cellspacing="0">
 <tr><td align="left" valign="top"><a 
href="subsubsection-_0060_0060simple_002ddouble_002d_002d.html">1.1.1.1 
subsubsection &ldquo;simple-double&ndash;</a></td><td>&nbsp;&nbsp;</td><td 
align="left" valign="top">
@@ -707,9 +708,10 @@ ul.no-bullet {list-style: none}
 </table></blockquote>
 
 <span id="anchor"></span>
-</div></td>
+</td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">  <a href="index.htm"><img
diff --git 
a/tp/tests/tex_html/res_parser/formatting_singular/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
 
b/tp/tests/tex_html/res_parser/formatting_singular/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
index c22e102..4088121 100644
--- 
a/tp/tests/tex_html/res_parser/formatting_singular/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
+++ 
b/tp/tests/tex_html/res_parser/formatting_singular/subsubsection-_0060_0060simple_002ddouble_002d_002d.html
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -696,12 +698,12 @@ ul.no-bullet {list-style: none}
 </table>
 </td>
 <td align="left">
-<div class="node" id="subsubsection-_0060_0060simple_002ddouble_002d_002d-1">
-<h4 class="subsubsection">1.1.1.1 subsubsection 
&ldquo;simple-double&ndash;</h4>
+<span id="subsubsection-_0060_0060simple_002ddouble_002d_002d-1"></span><h4 
class="subsubsection">1.1.1.1 subsubsection &ldquo;simple-double&ndash;</h4>
 
-</div></td>
+</td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">  <a href="index.htm"><img
diff --git 
a/tp/tests/tex_html/res_parser/formatting_singular/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
 
b/tp/tests/tex_html/res_parser/formatting_singular/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
index 86bd7fe..68a4939 100644
--- 
a/tp/tests/tex_html/res_parser/formatting_singular/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
+++ 
b/tp/tests/tex_html/res_parser/formatting_singular/subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027.html
@@ -630,6 +630,8 @@ truc: after a deff item
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -655,7 +657,6 @@ ul.no-bullet {list-style: none}
 
 <body lang="en"  background="../singular_images/Mybg.png">
 
-</div>
 <div class="subsubsection" 
id="subsubsection-three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027">
 <table border="0" cellpadding="0" cellspacing="0">
 <tr valign="top">
@@ -697,12 +698,12 @@ ul.no-bullet {list-style: none}
 </table>
 </td>
 <td align="left">
-<div class="node" id="three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027">
-<h4 class="subsubsection">1.1.1.2 three&mdash;four&mdash;-&rdquo;</h4>
+<span id="three_002d_002d_002dfour_002d_002d_002d_002d_0027_0027"></span><h4 
class="subsubsection">1.1.1.2 three&mdash;four&mdash;-&rdquo;</h4>
 
-</div></td>
+</td>
 </tr>
 </table>
+</div>
 <hr>
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">  <a href="index.htm"><img
diff --git a/tp/tests/tex_html/res_parser/math_not_closed/math_not_closed.html 
b/tp/tests/tex_html/res_parser/math_not_closed/math_not_closed.html
index 713b940..66adc19 100644
--- a/tp/tests/tex_html/res_parser/math_not_closed/math_not_closed.html
+++ b/tp/tests/tex_html/res_parser/math_not_closed/math_not_closed.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -40,14 +42,12 @@ ul.no-bullet {list-style: none}
 <p><SPAN CLASS="MATH"><IMG
  STYLE="height: 2.03ex; vertical-align: -0.31ex; " SRC="math_not_closed_1.svg"
  ALT="$\delta + 2
-$"></SPAN></p><div class="node" id="Chapter">
-<h1 class="chapter">1 Chapter</h1>
+$"></SPAN></p><span id="Chapter"></span><h1 class="chapter">1 Chapter</h1>
 
 <p><SPAN CLASS="MATH"><IMG
  STYLE="height: 2.03ex; vertical-align: -0.31ex; " SRC="math_not_closed_2.svg"
  ALT="$3\delta + 2
-$"></SPAN></p></div><hr></div>
-</div>
+$"></SPAN></p><hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/simplest_httex/simplest.html 
b/tp/tests/tex_html/res_parser/simplest_httex/simplest.html
index 8339f7c..ff55d67 100644
--- a/tp/tests/tex_html/res_parser/simplest_httex/simplest.html
+++ b/tp/tests/tex_html/res_parser/simplest_httex/simplest.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -35,12 +37,10 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 
-<div class="node" id="Top">
-
+<span id="Top"></span>
 <p>This is a very simple texi manual &nbsp; &lt;&gt;.
 </p>
-</div><hr></div>
-<p><font size="-1">
+<hr><p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
 
diff --git a/tp/tests/tex_html/res_parser/tex/tex.html 
b/tp/tests/tex_html/res_parser/tex/tex.html
index e61c5e0..8dcf329 100644
--- a/tp/tests/tex_html/res_parser/tex/tex.html
+++ b/tp/tests/tex_html/res_parser/tex/tex.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -35,8 +37,7 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
 <p>Now tex on the same line 
 <P>
@@ -123,8 +124,7 @@ Here some <!-- MATH
 $">
 </DIV>
 
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/tex_accents_httex/tex_accents.html 
b/tp/tests/tex_html/res_parser/tex_accents_httex/tex_accents.html
index e0157f0..a7e2fff 100644
--- a/tp/tests/tex_html/res_parser/tex_accents_httex/tex_accents.html
+++ b/tp/tests/tex_html/res_parser/tex_accents_httex/tex_accents.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 @import "tex_accents_tex4ht_tex.css";
diff --git a/tp/tests/tex_html/res_parser/tex_accents_l2h/tex_accents.html 
b/tp/tests/tex_html/res_parser/tex_accents_l2h/tex_accents.html
index a9fda9b..02d2f54 100644
--- a/tp/tests/tex_html/res_parser/tex_accents_l2h/tex_accents.html
+++ b/tp/tests/tex_html/res_parser/tex_accents_l2h/tex_accents.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
diff --git a/tp/tests/tex_html/res_parser/tex_complex_httex/tex_complex.html 
b/tp/tests/tex_html/res_parser/tex_complex_httex/tex_complex.html
index f3fff0a..c163c42 100644
--- a/tp/tests/tex_html/res_parser/tex_complex_httex/tex_complex.html
+++ b/tp/tests/tex_html/res_parser/tex_complex_httex/tex_complex.html
@@ -14,6 +14,8 @@ Some (I-D) \varphi(t) math. -->
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 @import "tex_complex_tex4ht_math.css";
@@ -60,8 +62,7 @@ class="cmmi-10">t</span>)  math.
 
 
 <div class="top" id="Top">
-<div class="node" id="The-title">
-<h1 class="top">The title</h1>
+<span id="The-title"></span><h1 class="top">The title</h1>
 
 
     <div class="math-display" >
@@ -92,7 +93,7 @@ class="cmmi-7">t</span></sup> .
 </p>
 <p>Now there is a footnote<a id="DOCF1" href="#FOOT1"><sup>1</sup></a>
 </p>
-</div><div class="footnote">
+<div class="footnote">
 <hr>
 <h3 class="footnotes-heading">Footnotes</h3>
 
@@ -111,7 +112,6 @@ class="cmmi-7">&#x03D5;</span></sup> .
 </p>
 </div>
 <hr></div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/tex_complex_l2h/tex_complex.html 
b/tp/tests/tex_html/res_parser/tex_complex_l2h/tex_complex.html
index fd387a6..3ecebdc 100644
--- a/tp/tests/tex_html/res_parser/tex_complex_l2h/tex_complex.html
+++ b/tp/tests/tex_html/res_parser/tex_complex_l2h/tex_complex.html
@@ -14,6 +14,8 @@ Some (I-D) \varphi(t) math. -->
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -64,8 +66,7 @@ $">
 
 
 <div class="top" id="Top">
-<div class="node" id="The-title">
-<h1 class="top">The title</h1>
+<span id="The-title"></span><h1 class="top">The title</h1>
 
 <DIV CLASS="displaymath">
 <!-- MATH
@@ -109,7 +110,7 @@ $">
 </p>
 <p>Now there is a footnote<a id="DOCF1" href="#FOOT1"><sup>1</sup></a>
 </p>
-</div><div class="footnote">
+<div class="footnote">
 <hr>
 <h3 class="footnotes-heading">Footnotes</h3>
 
@@ -137,7 +138,6 @@ $">
 </p>
 </div>
 <hr></div>
-</div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/tex_eqalign_httex/tex_eqalign.html 
b/tp/tests/tex_html/res_parser/tex_eqalign_httex/tex_eqalign.html
index e1311ed..4ad8a96 100644
--- a/tp/tests/tex_html/res_parser/tex_eqalign_httex/tex_eqalign.html
+++ b/tp/tests/tex_html/res_parser/tex_eqalign_httex/tex_eqalign.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 @import "tex_eqalign_tex4ht_displaymath.css";
@@ -38,8 +40,7 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
 
 <!--l. 5--><p class="indent" >
@@ -62,8 +63,7 @@ src="tex_eqalign_tex4ht_tex0x.png" alt="                      
              &#x2
 " class="math-display" ></div>
 <!--l. 8--><p class="indent" >     
 
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/tex_eqalign_l2h/tex_eqalign.html 
b/tp/tests/tex_html/res_parser/tex_eqalign_l2h/tex_eqalign.html
index a4cf685..33a669f 100644
--- a/tp/tests/tex_html/res_parser/tex_eqalign_l2h/tex_eqalign.html
+++ b/tp/tests/tex_html/res_parser/tex_eqalign_l2h/tex_eqalign.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -35,8 +37,7 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
 <DIV CLASS="displaymath">
 <!-- MATH
@@ -75,8 +76,7 @@ ul.no-bullet {list-style: none}
 </DIV>
 
 
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/tex_gdef_httex/tex_gdef.html 
b/tp/tests/tex_html/res_parser/tex_gdef_httex/tex_gdef.html
index 2edd032..fc54fe6 100644
--- a/tp/tests/tex_html/res_parser/tex_gdef_httex/tex_gdef.html
+++ b/tp/tests/tex_html/res_parser/tex_gdef_httex/tex_gdef.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 @import "tex_gdef_tex4ht_displaymath.css";
@@ -39,15 +41,13 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
    
 
 
 
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/tex_gdef_l2h/tex_gdef.html 
b/tp/tests/tex_html/res_parser/tex_gdef_l2h/tex_gdef.html
index 406f225..edf912d 100644
--- a/tp/tests/tex_html/res_parser/tex_gdef_l2h/tex_gdef.html
+++ b/tp/tests/tex_html/res_parser/tex_gdef_l2h/tex_gdef.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -35,8 +37,7 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
   
 
@@ -60,8 +61,7 @@ ul.no-bullet {list-style: none}
 $">
 </DIV>
 
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/tex_httex/tex.html 
b/tp/tests/tex_html/res_parser/tex_httex/tex.html
index 152266c..4fcfb10 100644
--- a/tp/tests/tex_html/res_parser/tex_httex/tex.html
+++ b/tp/tests/tex_html/res_parser/tex_httex/tex.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 @import "tex_tex4ht_displaymath.css";
@@ -39,8 +41,7 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
 <p>Now tex on the same line 
 <!--l. 5--><p class="indent" >
@@ -114,8 +115,7 @@ src="tex_tex4ht_displaymath0x.png" alt="                    
    (      )2
 " class="math-display" ></div>
 <!--l. 7--><p class="indent" >     
 
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
diff --git a/tp/tests/tex_html/res_parser/tex_in_copying/tex_in_copying.html 
b/tp/tests/tex_html/res_parser/tex_in_copying/tex_in_copying.html
index 3deaf85..2c1fc12 100644
--- a/tp/tests/tex_html/res_parser/tex_in_copying/tex_in_copying.html
+++ b/tp/tests/tex_html/res_parser/tex_in_copying/tex_in_copying.html
@@ -17,6 +17,8 @@ $$
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -53,8 +55,7 @@ ul.no-bullet {list-style: none}
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-<div class="node" id="Top-node">
-<h1 class="top">Top node</h1>
+<span id="Top-node"></span><h1 class="top">Top node</h1>
 
 <p>Some equation is indeed needed to understand the copyright of
 that file
@@ -97,7 +98,7 @@ $">
 
 </p>
 
-</div><hr size="6">
+<hr size="6">
 <div class="chapter" id="chapter">
 <table class="header" cellpadding="1" cellspacing="1" border="0">
 <tr><td valign="middle" align="left">[<a href="#Top" title="Beginning of this 
chapter or previous chapter"> &lt;&lt; </a>]</td>
@@ -114,8 +115,7 @@ $">
 <td valign="middle" align="left">[Index]</td>
 <td valign="middle" align="left">[<a href="#SEC_About" title="About (help)"> ? 
</a>]</td>
 </tr></table>
-<div class="node" id="chapter-1">
-<h1 class="chapter">1 chapter</h1>
+<span id="chapter-1"></span><h1 class="chapter">1 chapter</h1>
 
 <p>The fundamental equation is
 <DIV CLASS="displaymath">
@@ -151,7 +151,7 @@ $">
 </p>
 
 
-</div><hr size="6">
+<hr size="6">
 </div>
 </div>
 <div class="About_element" id="SEC_About">
diff --git a/tp/tests/tex_html/res_parser/tex_not_closed/tex_not_closed.html 
b/tp/tests/tex_html/res_parser/tex_not_closed/tex_not_closed.html
index f35c5b9..240551a 100644
--- a/tp/tests/tex_html/res_parser/tex_not_closed/tex_not_closed.html
+++ b/tp/tests/tex_html/res_parser/tex_not_closed/tex_not_closed.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -34,15 +36,13 @@ ul.no-bullet {list-style: none}
 </head>
 
 <body lang="en">
-<div class="node" id="Top">
-
+<span id="Top"></span>
 <p>texte
 </p>
 
 <P>
 This is some <SPAN 
CLASS="logo,LaTeX">L<SUP><SMALL>A</SMALL></SUP>T<SMALL>E</SMALL>X</SPAN>
-</div><hr></div>
-<p><font size="-1">
+<hr><p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>
 
diff --git a/tp/tests/tex_html/res_parser/tex_notex/tex.html 
b/tp/tests/tex_html/res_parser/tex_notex/tex.html
index 8f623f5..8461a61 100644
--- a/tp/tests/tex_html/res_parser/tex_notex/tex.html
+++ b/tp/tests/tex_html/res_parser/tex_notex/tex.html
@@ -10,6 +10,8 @@
 <meta name="resource-type" content="document">
 <meta name="distribution" content="global">
 <meta name="Generator" content="texi2any">
+<meta name="viewport" content="width=device-width,initial-scale=1">
+
 <style type="text/css">
 <!--
 a.copiable-anchor {visibility: hidden; text-decoration: none; line-height: 0em}
@@ -35,8 +37,7 @@ ul.no-bullet {list-style: none}
 
 <body lang="en">
 <div class="top" id="Top">
-<div class="node" id="Tests">
-<h1 class="top">Tests</h1>
+<span id="Tests"></span><h1 class="top">Tests</h1>
 
 <p>Now tex on the same line Some text one the line following @end tex
 </p>
@@ -69,8 +70,7 @@ Here some <em class='math'>{x^i}\over{\tan y}</em>.
 <p>Displaymath
 </p><div class="displaymath"><em>-- f(x) = {1 \over \sigma 
\sqrt{2\pi}}e<sup>-{1 \over 2}\left({x-\mu \over \sigma}\right)^2</sup>
 </em></div>
-</div><hr></div>
-</div>
+<hr></div>
 <p><font size="-1">
   This document was generated on <em>a sunny day</em> using <a 
href="http://www.gnu.org/software/texinfo/";><em>texi2any</em></a>.
 </font></p>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]