Need to change the decimal page number into topic title abbreviation #DITA-OT #PDF



I'm doing the dita-ot pdf conversion, using lot of topic dita template and requirement is to changing the decimal page numbers into the topic title abbreviation for one topic alone, other topic it should be in decimal page number only

In the commons.xsl

<xsl:template match="*[contains(@class, ' topic/topic ')]">

<xsl:when test="not(ancestor::*[contains(@class, ' topic/topic ')]) and not(ancestor::ot-placeholder:glossarylist)">
<fo:page-sequence master-reference="{$page-sequence-reference}" xsl:use-attribute-sets="__force__page__count" initial-page-number="1">
<xsl:call-template name="startPageNumbering"/>



    <xsl:attribute-set name="__force__page__count">
        <xsl:attribute name="force-page-count">
                <xsl:when test="name(/*) = 'bookmap'">
                    <xsl:value-of select="'even'"/>
                    <xsl:value-of select="'auto'"/>

There is no any templates for startPageNumbering, as per the initial-page-number and force_page_count, decimal page number getting reset for every topic as starting with page number 1. So that I just want to change the one topic decimal page number into the corresponding topic title abbreviation

for eg:

<topic class="- topic/topic ">
<title class="- topic/title " outputclass="CD_Section_Heading">DEFINITIONS</title>

for this DEFINITIONS topic page number should "DEF" as like that I have few topic that should get abbreviation as page number for that corresponding topic pages. Please help me and let me know if you need any more. Thanks in Advance!!!



You haven't mentioned which DITA OT version you're using but I guess this applies to all versions.
I think the page number is added with the static-content.xsl file. In there, there are templates for headers and footers where fo:page-number inserts the page number. I think the startPageNumbering template in the commons.xsl only allows you to enable start numbering on the first page of your document.
So maybe you could insert a conditional test in static-content.xsl and see if that works for you.



Thanks Christina, Its working fine as per your suggestion, but i'm having some issue to apply the changes for all the child topic, actually my input dita file having topics like this

<topic outputclass="h1">
   <title outputclass="CD_Map_Heading-hide">HIDE TOPIC</title>
   <topic outputclass="h2">
   <topic outputclass="h3">
<xsl:template name="insertBodyOddFooter">
    <fo:static-content flow-name="odd-body-footer">
        <fo:block xsl:use-attribute-sets="__body__odd__footer">
                <xsl:when test="contains(@outputclass, 'h2')">
<xsl:when test="contains(@outputclass, 'h3')">
<xsl:otherwise> <fo:block-container position="absolute"> <fo:block padding-top="20pt" text-align="center"> <fo:page-number/> </fo:block> </fo:block-container> </xsl:otherwise> </xsl:choose> </fo:block> </fo:static-content> </xsl:template>

I'm getting only DEF as footnote for all the topics.But I need separate footnote for each child topic. For the h3 attribute I need to get REV as footer value. But I'm getting only DEF. So please help me to get the footer value for that corresponding chils topic pages. Thanks in advance!!!



I guess this has been resolved with the following Oxygen forum entry, correct?