print current page/ last page number in my pdf out

35 views
Skip to first unread message

Shubham Pokhriyal

unread,
Oct 20, 2023, 12:57:32 AM10/20/23
to dita-o...@googlegroups.com
Hello everyone,

I need a help on page number related issue.

I want print current page/ last page number in my pdf out.


I am using:

<fo:block xsl:use-attribute-sets="__body__odd__footer">
                <fo:page-number/>
                <xsl:text> of </xsl:text>
                <fo:page-number-citation-last page-citation-strategy="all" ref-id="my-sequence-id"/>
                <fo:page-number-citation-last ref-id="id_last_flow"/>
            </fo:block>

But it is not working correctly.

Thanks and regards,
Shambhoo Prasad

Aaron DaMommio

unread,
Oct 20, 2023, 9:27:46 AM10/20/23
to Shubham Pokhriyal, DITA-OT Users
What output are you getting? 
Thanks,
Aaron DaMommio

--
You received this message because you are subscribed to the Google Groups "DITA-OT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dita-ot-user...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/dita-ot-users/CAChh1PqJLdcrbQD8%3DG3HiSbkjQdk%2B98h4%3DKgfKctEhXGJSn2mg%40mail.gmail.com.

Shubham Pokhriyal

unread,
Oct 20, 2023, 10:18:54 AM10/20/23
to Aaron DaMommio, DITA-OT Users
Hello Aaron Thanks for asking,

I was getting 1 / 0. But got the correct output by below code:
Current page/Total pages

<fo:static-content flow-name="odd-body-footer">
                    <fo:block xsl:use-attribute-sets="__body__odd__footer">
                        <fo:page-number/>
                        <xsl:text> / </xsl:text>
                        <fo:page-number-citation-last page-citation-strategy="all" ref-id="my-sequence-id"/>
                    </fo:block>
                </fo:static-content>
Reply all
Reply to author
Forward
0 new messages