This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Checking for existence


alex chang wrote:
> 
> What I want to do is to print the text of all the children of <row-header>,
> but only if <st-header> does not exist. So in the above, I would -not- print
> anything. Is there a way to do this?

Hi Alex

<xsl:template match="row-header">
  <xsl:if test="not(st-header) or normalize-space(st-header)=''">
    <xsl:apply-templates select="*[not(self::st-header)]" />
  </xsl:if>
</xsl:template>

Something in here should do what you want!

-- 
Warren Hedley


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]