The Simple Internationalization didn't work because some other problem , BUT the real
remaining
problem of the WAR deployment is that:
if you change the context path to a sub-site you cannot access resources that are
located above
the sub-site
For instance the following sub sites:
i18n:
line: <map:transform src="../stylesheets/system/error2html.xsl"/>
If you try this you get this:
---------------------
java.lang.RuntimeException: Problem in
getTransformer:zip:C:/bea/wlserver6.0sp1/config/mydomain/applications/.wl_temp_do_not_delete/wl_local_comp16144.war#i18n/../stylesheets/system/error2html.xsl
-----------------------
sub:
line <map:transform src="stylesheets/system/error2html.xsl"/>
-------------------
org.apache.cocoon.ProcessingException: Failed to execute
pipeline.:java.lang.RuntimeException:
Problem in
getTransformer:zip:C:/bea/wlserver6.0sp1/config/mydomain/applications/.wl_temp_do_not_delete/wl_local_comp26518.war#sub/stylesheets/system/error2html.xsl
-------------------
These are wrong URI, of course.
However, I'm not sure if it is a bug or proper behavior. If the protocol if "file:"
the "../"
works, but with other protocols? If you want to access the "upper" resource, shouldn't
you switch
context back or to use a specific protocol like "context:///"?
Jiri.
--- Davanum Srinivas <[EMAIL PROTECTED]> wrote:
> Oops...Sorry the Simple Internationalization is not working in WebLogic/WAR
>deployment (not the
> sub-sitemap's...)
>
> Thanks,
> dims
> --- [EMAIL PROTECTED] wrote:
> > dims 01/05/31 13:37:05
> >
> > Modified: src/org/apache/cocoon/environment AbstractEnvironment.java
> > Log:
> > Patch for Weblogic/WAR deployment - relative path issues
> > from Jiri Luzny ([EMAIL PROTECTED])
> > One problem left for WebLogic/WAR deployment. Sub-sitemaps are not working.....
> >
> > Revision Changes Path
> > 1.6 +17 -11
>xml-cocoon2/src/org/apache/cocoon/environment/AbstractEnvironment.java
> >
> > Index: AbstractEnvironment.java
> > ===================================================================
> > RCS file:
>/home/cvs/xml-cocoon2/src/org/apache/cocoon/environment/AbstractEnvironment.java,v
> > retrieving revision 1.5
> > retrieving revision 1.6
> > diff -u -r1.5 -r1.6
> > --- AbstractEnvironment.java 2001/05/29 17:04:54 1.5
> > +++ AbstractEnvironment.java 2001/05/31 20:37:05 1.6
> > @@ -117,19 +117,25 @@
> > this.prefix.append(prefix);
> > uri = uri.substring(prefix.length());
> >
> > + //if the resource is zipped into a war file (e.g. Weblogic temp
>deployment)
> > + if (this.context.getProtocol().equals("zip")) {
> > + this.context = new URL(this.context.toString() + context);
> > +
> > // if we got a absolute context or one with a protocol resolve
>it
> > - if (context.charAt(0) == '/') {
> > - this.context = new URL("file:" + context);
> > - }else if (context.indexOf(':') > 1) {
> > - this.context = new URL(context);
> > - }else {
> > - this.context = new URL(this.context, context);
> > - }
> > - File f = new File(this.context.getFile());
> > - if (f.isFile()) {
> > - this.context = f.getParentFile().toURL();
> > } else {
> > - this.context = f.toURL();
> > + if (context.charAt(0) == '/') {
> > + this.context = new URL("file:" + context);
> > + } else if (context.indexOf(':') > 1) {
> > + this.context = new URL(context);
> > + } else {
> > + this.context = new URL(this.context, context);
> > + }
> > + File f = new File(this.context.getFile());
> > + if (f.isFile()) {
> > + this.context = f.getParentFile().toURL();
> > + } else {
> > + this.context = f.toURL();
> > + }
> > }
> > } else {
> > getLogger().error("The current URI ("
> >
> >
> >
> >
> > ----------------------------------------------------------------------
> > In case of troubles, e-mail: [EMAIL PROTECTED]
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
>
>
> =====
> Davanum Srinivas, JNI-FAQ Manager
> http://www.jGuru.com/faq/JNI
>
> __________________________________________________
> Do You Yahoo!?
> Get personalized email addresses from Yahoo! Mail - only $35
> a year! http://personal.mail.yahoo.com/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]
>
__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35
a year! http://personal.mail.yahoo.com/
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]