Bug 97801 - Writer (X)HTML export: missing page numbers in Table of Contents
Summary: Writer (X)HTML export: missing page numbers in Table of Contents
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
4.1 all versions
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: (X)HTML-Export
  Show dependency treegraph
 
Reported: 2016-02-12 15:08 UTC by Martin Nathansen
Modified: 2023-06-10 03:14 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
the odt document to be exported and the resulting html (23.58 KB, application/zip)
2016-02-12 15:08 UTC, Martin Nathansen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Nathansen 2016-02-12 15:08:56 UTC
Created attachment 122579 [details]
the odt document to be exported and the resulting html

The page numbers in the Table of Contents (ToC) are getting lost during XHTML export of a LO writer document.

ToC before export (writer2html.odt):

Table of Contents
Heading1............................1
Heading2............................1
   Heading21........................1
   Heading22........................2

ToC after export via "File->Export->All Formats->XHTML (.html;.xhtml)" (writer2html.html):

Table of Contents
Heading1
Heading2
  Heading21
  Heading22

This HTML ToC export is realized by the XSL template „createIndexBodyTable“.
There is also a EasyHack related to this template, the task is to improve the ToC formatting for the HTML export:
https://bugs.documentfoundation.org/show_bug.cgi?id=89290
Comment 1 Buovjaga 2016-02-16 11:10:54 UTC
Reproduced.

Win 7 Pro 64-bit, Version: 5.1.0.3 (x64)
Build ID: 5e3e00a007d9b3b6efb6797a8b8e57b51ab1f737
CPU Threads: 4; OS Version: Windows 6.1; UI Render: default; 
Locale: fi-FI (fi_FI)
Comment 2 Martin Nathansen 2016-03-09 14:39:33 UTC
Regarding this bug report it is the other way around:

The output of the HTML export is just one page and therefore page numbers are meaningless. 

So the bug report should not be titled “missing page numbers ….” as in this bug report, it should be titled “not removed page numbers...”. 

The page numbers are correctly removed from LO Writer documents but not from AOO Writer documents.

So also the associated EasyHack makes no sense anymore:
https://bugs.documentfoundation.org/show_bug.cgi?id=89290
Comment 3 Gian Domenico Ceccarini 2017-01-17 09:49:41 UTC
So the goal of this easy hack is to remove page numbers when exporting Open Office Writer documents via "File->Export->All Formats->XHTML"?

I agree with Martin considering page numbers meaningless, but the purpose of this easy hack is not clear for me.
Comment 4 jani 2017-01-23 12:45:51 UTC
(In reply to Gian Domenico Ceccarini from comment #3)
> So the goal of this easy hack is to remove page numbers when exporting Open
> Office Writer documents via "File->Export->All Formats->XHTML"?
> 
> I agree with Martin considering page numbers meaningless, but the purpose of
> this easy hack is not clear for me.

Please be aware, this is not a easyhack, and thus considered more complicated.

The purpose of the bug is quite clear, the XHTML export, should not have page numbers. This is by the way not for openoffice (or AOO) documents but for LO documents.
Comment 5 QA Administrators 2018-06-27 02:48:30 UTC Comment hidden (obsolete)
Comment 6 QA Administrators 2020-06-27 03:49:42 UTC Comment hidden (obsolete)
Comment 7 Jelkersers 2020-11-05 04:41:16 UTC Comment hidden (spam)
Comment 8 Stéphane Guillou (stragu) 2021-05-18 13:14:38 UTC
I agree that this bug report should be closed as "not a bug". Page numbers should not appear as a HTML page is not paginated.

Instead, a new but report should be opened (if it doesn't exist already) about how "Save As > HTML" shows page numbers in the TOC, and the bottom of the page shows "Page x of x".

XHTML export does not show either.

Version: 7.2.0.0.alpha0+ / LibreOffice Community
Build ID: 6b09276d157abada74e1a4989700139167207778
CPU threads: 8; OS: Linux 4.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
TinderBox: Linux-rpm_deb-x86_64@86-TDF, Branch:master, Time: 2021-05-14_04:32:30
Calc: threaded
Comment 9 Buovjaga 2021-05-18 13:44:22 UTC
(In reply to stragu from comment #8)
> I agree that this bug report should be closed as "not a bug". Page numbers
> should not appear as a HTML page is not paginated.

A funny footnote, but these days page numbers make sense in some contexts thanks to CSS paged media:
https://developer.mozilla.org/en-US/docs/Web/CSS/Paged_Media
https://print-css.rocks/

Not in web browsers, though (except with a JavaScript polyfill).
Comment 10 Chris Y. 2021-06-09 03:50:13 UTC
Related:

Bug 142725 - Page numbers not removed from ToC when saved to HTML

https://bugs.documentfoundation.org/show_bug.cgi?id=142725
Comment 11 QA Administrators 2023-06-10 03:14:32 UTC
Dear Martin Nathansen,

To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year.

There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present.

If you have time, please do the following:

Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/

If the bug is present, please leave a comment that includes the information from Help - About LibreOffice.
 
If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice.

Please DO NOT

Update the version field
Reply via email (please reply directly on the bug tracker)
Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not 
appropriate in this case)


If you want to do more to help you can test to see if your issue is a REGRESSION. To do so:
1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from https://downloadarchive.documentfoundation.org/libreoffice/old/

2. Test your bug
3. Leave a comment with your results.
4a. If the bug was present with 3.3 - set version to 'inherited from OOo';
4b. If the bug was not present in 3.3 - add 'regression' to keyword


Feel free to come ask questions or to say hello in our QA chat: https://web.libera.chat/?settings=#libreoffice-qa

Thank you for helping us make LibreOffice even better for everyone!

Warm Regards,
QA Team

MassPing-UntouchedBug