You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Shannon Scott <ss...@locationinc.com> on 2007/12/14 15:38:36 UTC

Tomcat 5 SSI crossContext

Hello,
I have an application that needs to use server side includes (SSI ).  
The jsp server side includes work well from the ROOT application, but I 
am unable to use the jsp from another context as a server side include.  
I searched the archives and found other folks with this issue, but no 
solution.  To be clear, if my .shtml lokks like this:
<html>
<body>
<!--#include virtual="/index.jsp" -->
<!--#include virtual="/myTest/index.jsp" -->
</body>
</html>

The first include works but the second shows this on the page:
[an error occurred while processing this directive]

I have set crossContext to true.  Has anyone found a solution to this 
problem?
Thank you for any pointers or advice.
Shannon



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Tomcat 5 SSI crossContext

Posted by Mark Thomas <ma...@apache.org>.
Shannon Scott wrote:
> To be clear, if my .shtml lokks like this:
> <html>
> <body>
> <!--#include virtual="/index.jsp" -->
> <!--#include virtual="/myTest/index.jsp" -->
> </body>
> </html>
> 
> The first include works but the second shows this on the page:
> [an error occurred while processing this directive]
> 
> I have set crossContext to true.  Has anyone found a solution to this
> problem?

This works for me.

Things I noticed during testing this that might help:
- Enabling SSI in the global web.xml breaks every non-privileged context
- Broken contexts don't start
- The file I was trying to include was in a broken, non-privileged context
- Moving the SSI servlet config to the web.xml for the ROOT web app fixed
the broken contexts so the include worked.

HTH,

Mark

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org