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

Re: problem using Xalan from within a servlet

Subject: Re: problem using Xalan from within a servlet
From: "Sia Rahimi" <sia_rahimi@xxxxxxxxxxx>
Date: Fri, 04 Aug 2000 19:02:04 GMT
using xalan servlet
I use the same technique which works with tomcat as well as JServ.

xsltInput = new XSLTInputSource(new FileInputStream(xmlfile));
XSLTProcessor processor = XSLTProcessorFactory.getProcessor();
processor.process(
   xsltInput,
   new XSLTInputSource(new FileInputStream(stylesheet)),
   new XSLTResultTarget(response.getOutputStream()));

However, appart form classpath issues you have mentioned, one thing that I had to do was to pass the file names with full paths to the processor using:

xmlfile = getServletContext().getRealPath(xmlfile);

Hope this helps. If it doesn't, then we can look at the configurations.



From: andreg@xxxxxxxxxxxxx
Reply-To: xsl-list@xxxxxxxxxxxxxxxx
To: XSL-List@xxxxxxxxxxxxxxxx
Subject: problem using Xalan from within a servlet
Date: Fri, 04 Aug 2000 01:28:17 -0500

I have a servlet which is doing XSL transformations to create the
presentation view. Everything works just fine in IBM WebSphere. Now I
tried to get the same testcase running in Tomcat 3.1, but for some
reason it doesn't work. What happens is that I get the stylesheet itself
returned, instead of the transformed output document. I also get a
warning about a missing version attribute in the stylesheet, although
the stylesheet has a version attribute. I use Xalan 1.1, by the way. I
wonder what could make the XSL processor spit out the input stylesheet
and not process anything at all.
In the classpath of the web application, I have the xalan and xerces jar
files first and then the xml.jar which comes with Tomcat. Everything
runs and compiles fine, until I start processing stylesheets.

Has anyone run into this before? Any suggestions?

Thanks in advance,
Andre Tost


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

________________________________________________________________________ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com


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.