Click here to Skip to main content
15,887,410 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hai, I have problem with footnote and endnote , my sample xml is

XML
  xml content<xref ref-type="fn" rid="FN-fn-11">
		<sup>3</sup>
	</xref>content xml
	<xref ref-type="fn" rid="FN-fn-12">
		<sup>4</sup>
	</xref>content xml<xref ref-type="fn" rid="FN-fn-13">
		<sup>5</sup>
	</xref>content xml
	<xref ref-type="fn" rid="FN-fn-14">
		<sup>6</sup>
	</xref>
	
	
<fn-group content-type="footnotes">
	<fn fn-type="footnote" id="FN-fn-11">
		<label>
			<sup>3</sup>
		</label>
		<p>para term 3</p>
	</fn>
	
	<fn fn-type="footnote" id="FN-fn-12">
		<label>
			<sup>4</sup>
		</label>
		<p>para term 4</p>
	</fn>
	
	<fn fn-type="footnote" id="FN-fn-13">
		<label>
			<sup>5</sup>
		</label>
		<p>para term 5</p>
	</fn>
	
	<fn fn-type="footnote" id="FN-fn-14">
		<label>
			<sup>6</sup>
		</label>
		<p>para term 6</p>
	</fn>
<fn-group>



in this i convert all footnote using xslt

XML
<xsl:template match="//xref">
    <xsl:variable name="rid" select="@rid"/>
    <xsl:choose>
      <xsl:when test="(ancestor::*//fn[@id = $rid]/parent::fn-group[@content-type='footnotes']/parent::table-wrap-foot  or ancestor::fn or ancestor::en)">
        <fo:inline>
          <xsl:apply-templates/>
        </fo:inline>
      </xsl:when>
        <xsl:when test="ancestor::*//fn-group[@content-type='footnotes']/fn[@id = $rid]">
        <fo:footnote>
          <fo:inline>
            <xsl:value-of select="."/>
          </fo:inline>
          <fo:footnote-body provisional-label-separation="0pt" provisional-distance-between-starts="18pt" space-after.optimum="6pt">
            <xsl:for-each select="ancestor::*//fn-group[@content-type='footnotes']/fn[@id = $rid]/p">
              <xsl:apply-templates select="."/>
            </xsl:for-each>
          </fo:footnote-body>
        </fo:footnote>
      </xsl:when>	
</xsl:template>


but now all footnote will place as end notes in my knowledge xslt dont have <fo:endnote xmlns:fo="#unknown"> any one give better solution
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900