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

Re: Schema declarations showing up in my html

Subject: Re: Schema declarations showing up in my html
From: David Carlisle <davidc@xxxxxxxxx>
Date: Sat, 2 Apr 2005 00:26:05 +0100
Re:  Schema declarations showing up in my html
> I realize this may be more of a .net question, but u guys are so much
> better than those other forums.

I suspect that it's just an xslt question, but it's hard to be sure as
you only posted your .net code which I don't think is relevant.


  <element xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">elementvalue</element>

  every single time I do a <xsl:copy-of select="element" in my xsl

when you do copy-of you copy a node and it gets copied along with all
its namespaces children attributes etc, so presumably the xsi namespace
was in scope on the element that you copied. If this namespace is not on
any ancestor node in the result, copying the namespace node for this
element will cause a namespace declaration to be output.

if you wouldn't mind just getting one xmlns:xsi at the top level just
make sure that your top level result element uses this namespace.

If you don't want this namespace at all, then you either need to make
sure it is not in your source, or make sure you don't copy it
for example replace
<xsl:copy-of select="element"/>
by
<xsl:element name="element">
 <xsl:copy-of select="@*"/>
</xsl:element>

If the xsi namespace isn't in your source, then my guess is wrong and
you can ignore all the above.

David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

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.
Email
First Name
Last Name
Company
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.