[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

selecting not(node()) not working as I expect it to

Subject: selecting not(node()) not working as I expect it to
From: "Spencer Tickner" <spencertickner@xxxxxxxxx>
Date: Mon, 27 Feb 2006 10:26:05 -0800
xsl not node
Hello everyone,

For some reason (Monday perhaps) I'm having a very difficult time with
a very simple concept. I'm simply trying to apply all templates except
a node and then apply that node and it's children. I've done this
before with no issue,, now, well I'm having issues.


<?xml version="1.0"?>
				<para>This is a paragraph</para>
				<para>This is a paragraph
					<list mark="bull">
						<listitem>This is a list</listitem>
						<listitem>This is a list</listitem>
				<para>This is another paragraph</para>


<?xml version='1.0'?>
<xsl:stylesheet version="1.0"

<xsl:template match="/">

<xsl:template match="para">
	<p><xsl:apply-templates select="*[not(self::list)]"/></p>
	<xsl:apply-templates select="list"/>
<xsl:template match="para/text()">
	<xsl:value-of select="."/>
<xsl:template match="list">
<xsl:template match="listitem">

expected output

<p>This is a paragraph</p>
<p>This is a paragraph</p>
  <li>This is a list</li>
  <li>This is a list</li>
<p>This is another paragraph</p>

what I'm getting

						<li>This is a list</li>
						<li>This is a list</li>

any thoughts?

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.