This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes XML and Related Technologies and the fly likes Problem with Tomcat, Xerces and Xalan Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "Problem with Tomcat, Xerces and Xalan" Watch "Problem with Tomcat, Xerces and Xalan" New topic
Author

Problem with Tomcat, Xerces and Xalan

Rami Sawas
Ranch Hand

Joined: Jan 25, 2004
Posts: 41
Hi,
I downloaded the following:
jakarta-tomcat-5.0.18
j2sdk1.4.2_03
Tomcat is working fine with SDK. Then I decided to use the following:
XML Parser: Xerces
XSLT Processor: Xalan
Been told only to download Xalan because it also includes Xerces. So I downloaded this:
xalan-j_2_5_2-bin
Straight forward questions:
1) Where do I unzip the Xalan to? Where do I put its files...in the SDK directory?
2) How do I set the environment variables in this case?
I downloaded a ZIP file from the Internet cotaining the source code of a shopping cart. On a seperate PDF file it says the following setup steps:
A - copy framework.war to %TOMCAT_HOME%\webapps
B - modify %TOMCAT_HOME%\bin\tomcat.bat so CLASSPATH contains xerces.jar BEFORE %TOMCAT_HOME%\lib\xml.jar
A - Does this mean unzip the shopping cart file into the Tomcat specified folder?
B - Where do you do this?
This is what I did to make Tomcat and SDK work together...
name: JAVA_HOME
path: C:\j2sdk1.4.2_03 (must be the directory you installed the sdk)
then edit PATH and add this to the value
%JAVA_HOME%\bin

Thank you and look forward to hearing from you.
Rami

Edit: Lasse changed the subject of your post to something more appropriate
[ February 04, 2004: Message edited by: Lasse Koskela ]
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
In fact, Xalan does not include Xerces. You need to download Xerces separately.
Regarding what to unzip and where, the golden rule is only .jar files matter in the classpath. In other words, unzip the xalan.zip (and xerces.zip) anywhere and only copy the .jar files (xalan.jar, xercesImpl.jar) into the "lib" directory according to whatever guide you're following.


Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Rami Sawas
Ranch Hand

Joined: Jan 25, 2004
Posts: 41
I found the .jar files, I would just have to make a copy of it and paste it in the 'lib'directory. What's 'lib' directory by the way?
Thank you.
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
Originally posted by Rami Sawas:
What's 'lib' directory by the way?
It's either your web application's lib directory (WEB-INF/lib) or the shared lib directory of Tomcat (just find the other .jar files from the Tomcat directory.
 
Consider Paul's rocket mass heater.
 
subject: Problem with Tomcat, Xerces and Xalan