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

Namespace issue, possibly FAQ

Subject: Namespace issue, possibly FAQ
From: "Michael Semcheski" <mhs-list@xxxxxxxxx>
Date: Tue, 25 Feb 2003 14:36:30 -0500
microsoft namespace
Hi all,
I have an XML document which I am trying to transform (and don't we all).

The document begins with the root:
<?xml version="1.0"?>
<Workbook xmlns="urn:schemas-microsoft-com:office:spreadsheet"
 xmlns:o="urn:schemas-microsoft-com:office:office"
 xmlns:x="urn:schemas-microsoft-com:office:excel"
 xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"
 xmlns:html="http://www.w3.org/TR/REC-html40">
 <Styles>
  <Style ss:ID="Default" ss:Name="Normal">
   <Alignment ss:Vertical="Bottom"/>
   <Borders/>
   <Font/>
   <Interior/>
   <NumberFormat/>
   <Protection/>
  </Style>
(This is an excel spreadsheet saved as XML, so I omitted certain parts rom
in between the root and Styles elements).

I have the following stylesheet root in my XSLT file --
<?xml version="1.0"?>
<xsl:stylesheet 
 xmlns="urn:schemas-microsoft-com:office:spreadsheet"
 xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
 xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"
 version="1.0"
 >

I can get the correct elements with tags like:
	<xsl:template match="/">
		<xsl:apply-templates select="ss:Workbook"/>
	</xsl:template>

But I can't figure out a way to get the "ss:" out from in front of basically
every I am trying to touch.

It's a pretty big file, and a pretty complicated transform, and it only
makes it more complicated with the "ss:".  So the question, I guess, is how
can I avoid putting that prefix in front of all of my elements?


------------------------------
Michael H. Semcheski
Developer, Livewire Media


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


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.