You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by Sc...@lotus.com on 2001/05/22 23:17:01 UTC

Re: Help!!!

Can someone of one of the lists help Cindy?  I'm afraid  I'm rather low on
time this week...

-scott




                                                                                                                    
                    "Carlson,                                                                                       
                    Cindy                 To:     "'scott_boag@lotus.com'" <sc...@lotus.com>                   
                    (N-Sterling)"         cc:                                                                       
                    <cindy.carlson        Subject:     Help!!!                                                      
                    @lmco.com>                                                                                      
                                                                                                                    
                    05/22/2001                                                                                      
                    04:19 PM                                                                                        
                                                                                                                    
                                                                                                                    




Dear Mr. Boag:

I am attempting to use Xalan to transform my XML into HTML based ona very
simple stylesheet. I have successfully done the transformation in a Java
driver but I cannot get the transformation to work in my servlet. I always
get an exception when I call the newTransformer() method. The message is
"Namespace not supported by SAXParser". Can you tell me what I may be doing
wrong? It looks to me like my servlet code is the same as your example
(XSLTServletWithParams.java). I can't understand why I can do the
transformation in XmlSpy or using Xalan in a Java driver, but not using
Xalan in a servlet. Can you help me?

I have attached the servlet source in case that will help.

Thanks,
Cindy Carlson

 <<SwiftServlet.java>>
(See attached file: SwiftServlet.java)


Re: Help!!!

Posted by jason heddings <Ja...@Sun.COM>.
Cindy-

Make sure that you have the latest version of the Xalan processor and
(more importantly) make sure that all references to the xalan.jar file
and the xerces.jar file come before any references to crimson.jar in
your web server's CLASSPATH.

HTH,
--jah


Scott_Boag@lotus.com wrote:
> 
> Can someone of one of the lists help Cindy?  I'm afraid  I'm rather low on
> time this week...
> 
> -scott
> 
> 
>                     "Carlson,
>                     Cindy                 To:     "'scott_boag@lotus.com'" <sc...@lotus.com>
>                     (N-Sterling)"         cc:
>                     <cindy.carlson        Subject:     Help!!!
>                     @lmco.com>
> 
>                     05/22/2001
>                     04:19 PM
> 
> 
> 
> Dear Mr. Boag:
> 
> I am attempting to use Xalan to transform my XML into HTML based ona very
> simple stylesheet. I have successfully done the transformation in a Java
> driver but I cannot get the transformation to work in my servlet. I always
> get an exception when I call the newTransformer() method. The message is
> "Namespace not supported by SAXParser". Can you tell me what I may be doing
> wrong? It looks to me like my servlet code is the same as your example
> (XSLTServletWithParams.java). I can't understand why I can do the
> transformation in XmlSpy or using Xalan in a Java driver, but not using
> Xalan in a servlet. Can you help me?
> 
> I have attached the servlet source in case that will help.
> 
> Thanks,
> Cindy Carlson
> 
>  <<SwiftServlet.java>>
> (See attached file: SwiftServlet.java)
> 
>   ------------------------------------------------------------------------
>                         Name: SwiftServlet.java
>    SwiftServlet.java    Type: unspecified type (application/octet-stream)
>                     Encoding: base64

-- 

 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      \\\|///                 Jason Heddings             ((
     \\ ~ ~ //                303.272.5166 (x75166)    C|~~|
     (/ @ @ /)                Jason.Heddings@Sun.COM    `__'
 ~~oOOo~(_)~oOOo~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Re: Help!!!

Posted by René Jensen <lu...@tbkol.dk>.
Hey Cindy
> Can someone of one of the lists help Cindy?  I'm afraid  I'm rather low on
> time this week...
>
> -scott


> Dear Mr. Boag:
>
> I am attempting to use Xalan to transform my XML into HTML based ona very
> simple stylesheet. I have successfully done the transformation in a Java
> driver but I cannot get the transformation to work in my servlet. I always
> get an exception when I call the newTransformer() method. The message is
> "Namespace not supported by SAXParser". Can you tell me what I may be
doing
> wrong? It looks to me like my servlet code is the same as your example
> (XSLTServletWithParams.java). I can't understand why I can do the
> transformation in XmlSpy or using Xalan in a Java driver, but not using
> Xalan in a servlet. Can you help me?
>
> I have attached the servlet source in case that will help.
>
> Thanks,
> Cindy Carlson

This may not be a problem with your code, but with your servlet-engine.
Which servlet engine are you using..??

I had some problems using TomCat. The servlet engine comes with its own
xml-parser jarfiles.
The problem is, that when you start Tomcat (and I belive other servlet
engines do the same) all the jars used by the engine is prepended to your
classpath, caursing the servlet to use these jar-files instead of the one
usually used by applications.

I fixed the startup files for the servlet engine, so that all jarfiles where
appended to my classpath, instead of prepended, and that solved my problem.

               _\|/_
               (@ @)
-----------oOOo-(_)-oOOo-----------
If you have to get used to it...
           ...it's not good enough.
-----------------------------------
            René Jensen
         lundeman@tbkol.dk