Maketoc : Displayed number TOC second level
- Status
- Open
- Subject
- Maketoc : Displayed number TOC second level
- Version
- 18.x Regression
- Category
- Regression
- Resolution status
- New
- Submitted by
- David_Crossman
- Lastmod by
- David_Crossman
- Rating
- Description
Hi Tiki community,
I want to validate if from Tiki 18 the displayed number of a TOC is by default always showing the first Level of a title even if we specify only the second level
Table of contents
La fonction « recherche » dans le moteur de recherche de Foncierpédia
We had in TIki 15 :TABLE DES MATIÈRES
1. La fonction « recherche » dans le moteur de recherche de Foncierpédia
1. Les mots clés à éviterNow we have in Tiki18.4
TABLE DES MATIÈRES
1.1. La fonction « recherche » dans le moteur de recherche de Foncierpédia
1.2. Les mots clés à éviterPart of the code where it seems to make the difference in parserlib.php file : V15
// Update last_hdr info for the next header
$last_hdr = $hdr_structure$nb_hdrs;
$nb_last_hdr = count($last_hdr);
$current_title_real_num = implode('.', $hdr_structure$nb_hdrs).'. ';
if ( $hideall
// Update the current title number to hide all parents levels numbers if the parent has no autonumbering
$hideall = false;
for ( $j = $hdrlevel ; $j > 0 ; $j-- ) {
empty($show_title_level$j)) {empty($show_title_level$j) ) { unset($hdr_structure$nb_hdrs$j - 1); $hideall = true; } } // Store the title number to use only if it has to be shown (if the '#' char is used) $current_title_num = $show_title_level$hdrlevel ? implode('.', $hdr_structure$nb_hdrs).'. ' : ''; $nb_hdrs++; In v18 // Update last_hdr info for the next header $last_hdr = $hdr_structure$nb_hdrs; $nb_last_hdr = count($last_hdr); if (is_array($last_hdr)) { $current_title_real_num = implode('.', $last_hdr) . '. '; } else { $current_title_real_num = $last_hdr . '. '; } // Update the current title number to hide all parents levels numbers if the parent has no autonumbering $hideall = false; for ($j = $hdrlevel; $j > 0; $j--) { if ($hideall unset($hdr_structure$j - 1);
$hideall = true;
}
}// Store the title number to use only if it has to be shown (if the '#' char is used)
$current_title_num = '';
if $hdrlevel) && isset($hdr_structure$nb_hdrs" class="wiki wikinew text-danger tips isset">$show_title_level$hdrlevel) && isset($hdr_structure$nb_hdrs {
$current_title_num = $show_title_level$hdrlevel ? implode('.', $hdr_structure$nb_hdrs) . '. ' : '';
}$nb_hdrs++;
- Importance
- 8
- Priority
- 40
- Demonstrate Bug on Tiki 19+
-
This bug has been demonstrated on show2.tiki.org
Please demonstrate your bug on show2.tiki.org
Show.tiki.org is not configured properlyThe public/private keys configured to connect to show2.tiki.org were not accepted. Please make sure you are using RSA keys. Thanks.
- Demonstrate Bug (older Tiki versions)
-
This bug has been demonstrated on show.tikiwiki.org
Please demonstrate your bug on show.tikiwiki.org
Show.tiki.org is not configured properlyThe public/private keys configured to connect to show.tikiwiki.org were not accepted. Please make sure you are using RSA keys. Thanks.
- Ticket ID
- 7240
- Created
- Thursday 16 January, 2020 20:33:16 UTC
by David_Crossman - LastModif
- Thursday 16 January, 2020 20:33:16 UTC