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

Namespace issue when using Xalan

Subject: Namespace issue when using Xalan
From: Andrew Male <ccsajm@xxxxxxxxxx>
Date: Thu, 23 Dec 2004 17:12:03 +0000
andrew male
I have a stylesheet that seems to work for me when using Xalan on the command line. The problem presents itself when I attempt the transform from within a java class that I am using:

The java constructs an rss 2.0 valid file with an extra element defined in its own namespace, this element is <uobnews:sticky>:

<http://staff.bath.ac.uk/ccsajm/namespace-issue/index.xml>

The xsl that I am using to process this file is:

<http://staff.bath.ac.uk/ccsajm/namespace-issue/html-news-index.xslt>

Basically using the Xpath <xsl:value-of select="uobnews:sticky";> when the context node is <item> does not return the expected value when this transform is done from within my java code. The java is using Xalan 2.6.0, if however I run this through the same Xalan processor on the command line it works. I tested this doing the transform in XMLspy and this also transforms correctly, this was using the built in transformer and MSXML.

In the java I am using the jaxp apis to do the transform and use the recommended -Djava.endorsed.dirs when running the class to make sure that I am definitely using the same version of Xalan as when I run on the command line.

For some reason when the transform is initiated from within the java code it is not able to match the node in the uobnews namespace, it seems perhaps that the namespace is not available...... ??

Any, and I mean absolutely any suggestions would be gratefully received.

Thanks, Andrew

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.