| Subject: Re: [xsl] checking sequential element From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx> Date: Wed, 31 Dec 2008 11:21:22 -0500 | 
<xsl:template match="citau">
  <xsl:if test="not(following-sibling::*[1]/self::delim)">
    <xsl:message>citau does not followed by delim</xsl:message>
  </xsl:if>
</xsl:template>Cheers, Wendell
I think, you should do
<xsl:template match="citref"> <xsl:if test="not(citaug/citau/following-sibling::*[1]/self::delim)"> <xsl:message>citau does not followed by delim</xsl:message> </xsl:if> </xsl:template>
you were missing a 'not' and one missing level.
On Wed, Dec 31, 2008 at 12:00 PM, Ganesh Babu N <nbabuganesh@xxxxxxxxx> wrote: > Dear All, > > I want to test the presence of <delim/> tag after </citau> in the > below example. If it is missing the XSL should raise an error. > > <citref id="bib12"> > <citaug> > <citau> > <citsname>Ferri</citsname> > <delim/> > <citfnames>E</citfnames> > </citau> > <delim/> > <cittext>(ed.).</cittext> > </citaug> > > I have tried the following code but i am not getting the required result. > > <xsl:template match="citref"> > <xsl:if test="citau/following-sibling::*[1]/self::delim"> > <xsl:message>citau does not followed by delim</xsl:message> > </xsl:if> > </xsl:template> > > Please help me in getting the desired result.
====================================================================== Wendell Piez mailto:wapiez@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9635 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ======================================================================
| Current Thread | 
|---|
| 
 | 
| <- Previous | Index | Next -> | 
|---|---|---|
| Re: [xsl] checking sequential eleme, Mukul Gandhi | Thread | RE: [xsl] checking sequential eleme, Michael Kay | 
| RE: [xsl] Regex and apply xsl numbe, Michael Kay | Date | [xsl] Help with creating Task child, Charles Flanders | 
| Month |