[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: suprised by <xsl:copy-of select="@*"/>
Hi Gerry,
At 03:08 PM 8/6/01, you wrote: Why did I get <td colspan="2" bgcolor="#CC0000"> instead of <td>colspan="2" bgcolor="#CC0000" ????? because when you said <xsl:copy-of select="@*"/> the processor recognizes you are copying attribute nodes, and attribute nodes can only exist on element nodes, so that's where it puts them. When serialized, the element node with its associated attribute nodes gets written <td colspan="2" bgcolor="#CC0000">. Remember, it's nodes we're processing not strings! The <xsl:attribute> instruction works the same way. Notice that it's an error in your stylesheet to say <xsl:attribute> or <xsl:copy-of select="@*"> (both of which create attribute nodes) *after* instructions to put child nodes of the element into the tree. Cheers, Wendell
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|