Wrox Programmer Forums
Go Back   Wrox Programmer Forums > XML > XSLT
|
XSLT General questions and answers about XSLT. For issues strictly specific to the book XSLT 1.1 Programmers Reference, please post to that forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XSLT section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 25th, 2011, 09:59 AM
Friend of Wrox
 
Join Date: Nov 2007
Posts: 1,243
Thanks: 0
Thanked 245 Times in 244 Posts
Default

Please summarize, how does your current stylesheet look, how does the output you want look, how does the output you currently get look.
__________________
Martin Honnen
Microsoft MVP (XML, Data Platform Development) 2005/04 - 2013/03
My blog
 
Old October 25th, 2011, 10:09 AM
samjudson's Avatar
Friend of Wrox
 
Join Date: Aug 2007
Posts: 2,128
Thanks: 1
Thanked 189 Times in 188 Posts
Default

Because you have not used the prefix in the template you have specified it is using the built in XSLT template which will always output the inner text nodes of any element and its children.
__________________
/- Sam Judson : Wrox Technical Editor -/

Think before you post: What have you tried?
 
Old October 25th, 2011, 10:19 AM
mhkay's Avatar
Wrox Author
 
Join Date: Apr 2004
Posts: 4,962
Thanks: 0
Thanked 292 Times in 287 Posts
Default

>why do i get a dump of data inn the middle of my output xml file

Almost certainly because you are doing an apply-templates that selects nodes for which you have not defined any processing rules (template rules). A good coding practice is to catch these with a fallback template:

Code:
<xsl:template match="*">
  <xsl:message>Warning: no template rule defined for element <xsl:value-of select="name()"/></xsl:message>
</xsl:template>
__________________
Michael Kay
http://www.saxonica.com/
Author, XSLT 2.0 and XPath 2.0 Programmer\'s Reference





Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting Started R1chardK Perl 2 August 19th, 2009 11:22 PM
Getting Started... aweTastic SharePoint Development 2 April 10th, 2009 04:42 AM
Getting Started st3ve Javascript How-To 1 February 3rd, 2005 08:49 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.