OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: problem with position()


I'm trying to define a template to generate a particular xref label for 
DB->XHTML translation.

I'm using this simple template:

<!-- This naming style assumes that a section has at most one
      orderedlist child. -->
<xsl:template match="d:section/d:orderedlist/d:listitem" mode="xref-to">
   <xsl:param name="referrer"/>
   <xsl:param name="xrefstyle"/>

However, this always results in a label of the form "[...]/1", i.e. the 
reported position is "1", no matter whether the matched listitem is 
actually the first or not. (Please find attached a little test doc that 
results in:

"Some text referencing [A]/1, [A]/1, and [A]/1."

(where I would expect "[A]/1, [A]/2, and [A]/3".)

Does anyone see the error ? (The links themselves are correct.)



       ...ich hab' noch einen Koffer in Berlin...
<?xml version="1.0" encoding="UTF-8"?>
<book version="5.0" xmlns="http://docbook.org/ns/docbook";
      <title>A title</title>
      <listitem xml:id="l1">L1</listitem>
      <listitem xml:id="l2">L2</listitem>
      <listitem xml:id="l3">L3</listitem>      
    <para>Some text referencing <xref linkend="l1"/>, <xref linkend="l2"/>, and <xref linkend="l3"/>.</para>

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]