[opencms-dev] using jstl import from another context to access OC pages

Rob Wunderlich rob_wunderlich at yahoo.com
Thu Nov 30 02:39:14 CET 2006


I'm trying to include OC content in another webapp, "webappA". I've enabled crossContext=true for
both apps. In my "webappA" page, I use an import statement like:
<c:import url="/opencms/foo.jsp" context="/opencms"/>

The import executes but the content written is the "Welcome to CMS" page -- the same page seen
when using only the servlet name in a URL like http://localhost/opencms/opencms.

The import works correctly if I use an absolute URL like:
<c:import url="http://localhost/opencms/opencms/foo.jsp" context="/opencms"/>
However, using the absolute URL is not acceptable. 

The behavior I'm seeing when using the relative URL is that everything after /opencms/ seems to be
ignored. If I use a non-existent page, I also get the welcome screen instead of a status 404.

Has anyone done this successfully?

Thanks,
Rob


 
____________________________________________________________________________________
Do you Yahoo!?
Everyone is raving about the all-new Yahoo! Mail beta.
http://new.mail.yahoo.com



More information about the opencms-dev mailing list