[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [docbook-apps] olinking to varlistentry with indexterm inside term
Hi Bob, I've added the above template to my customization layer and I'm getting something like this in my XHTML output: <div> <a href="../mcs_themes/theme_border_prop.html#border-color" class="olink"></a> <a id="id8856773342938128" class="indexterm"></a> border-color </div> and the link does not work. Thanks, Robert BTW. I use DocBook XSL version 1.75.1. On Tue, Aug 2, 2011 at 7:51 PM, Bob Stayton <bobs@sagehill.net> wrote: > Hi, > This turns out to be a bug in how the cross reference text to a varlistentry > is generated. The indexterm in the term is generating an empty <a name> > anchor as part of the xref text. When that is wrapped with the <a href> to > make the link, that produces an invalid nested <a> and browsers don't > display it as a link. > > This template could be added to your customization layer to patch the > problem. I'll fix it in the XSL source files for the next release. > > <xsl:template match="d:varlistentry/d:term" mode="xref-to"> > <xsl:param name="referrer"/> > <xsl:param name="xrefstyle"/> > > <xsl:apply-templates mode="no.anchor.mode"/> > </xsl:template> > > The mode="no.anchor.mode" causes it to omit indexterms from the xref text. > > Bob Stayton > Sagehill Enterprises > bobs@sagehill.net > > > ----- Original Message ----- From: "Robert Pasternak" <rp.info@gmail.com> > To: "Bob Stayton" <bobs@sagehill.net> > Cc: <docbook-apps@lists.oasis-open.org> > Sent: Monday, August 01, 2011 11:50 PM > Subject: Re: [docbook-apps] olinking to varlistentry with indexterm inside > term > > > Hi, > > I use xhtml/profile-chunk.xsl. > > > Robert > > On Mon, Aug 1, 2011 at 8:07 PM, Bob Stayton <bobs@sagehill.net> wrote: >> >> Hi, >> It works for me in PDF output. Does your XML file validate? You didn't >> mention what kind of output you are generating. >> >> Bob Stayton >> Sagehill Enterprises >> bobs@sagehill.net >> >> >> ----- Original Message ----- From: "Robert Pasternak" <rp.info@gmail.com> >> To: <docbook-apps@lists.oasis-open.org> >> Sent: Monday, August 01, 2011 7:13 AM >> Subject: [docbook-apps] olinking to varlistentry with indexterm inside >> term >> >> >>> Hi, >>> >>> Let's consider the following XML fragment: >>> >>> <varlistentry xml:id="border-color"> >>> <term>border-color</term> >>> <listitem> >>> <para>Specifies the color of all four borders of an >>> element.</para> >>> </listitem> >>> </varlistentry> >>> >>> When I use <olink targetptr="border-color"/>, then the link to the >>> varlistentry is created properly. >>> Now, if there is an indexterm element like this: >>> >>> <varlistentry xml:id="border-color"> >>> <term> >>> <indexterm xml:id="id8856773342938128"> >>> <primary>themes</primary> >>> <secondary>border style properties</secondary> >>> <tertiary>border-color</tertiary> >>> </indexterm>border-color</term> >>> <listitem> >>> <para>Specifies the color of all four borders of an >>> element.</para> >>> </listitem> >>> </varlistentry> >>> >>> then the same <olink targetptr="border-color"/> does not generate a >>> link, even though it properly outputs the label, i.e. "border-color" >>> text. >>> >>> Any ideas what's wrong with my docbook page? >>> >>> Robert >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org >>> For additional commands, e-mail: docbook-apps-help@lists.oasis-open.org >>> >>> >>> >> >> > > >
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]