cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lajos Moczar <lm...@galatea.com>
Subject Re: URL rewriting solution in FAQ does not do the trick
Date Tue, 18 Jun 2002 15:56:46 GMT
Why not do this in $CATALINA_HOME/conf/server.xml:

<Context path="" docBase="cocoon"
  debug="0" reloadable="true"/>

Regards,

Lajos


Robert Bourdeau wrote:

> This is more of an Apache question than a Cocoon question, but
> hopefully someone will know what I'm doing wrong here.
> 
> Setup: SPARC Solaris 2.7, Apache 1.3.24 w/mod_webapp (Warp), and Tomcat 4.0.1
> 
> Goal:  Eliminate cocoon from the URL
> Constraints:  Want all my custom content (XML, stylesheets, etc.) to be removed
> from the Cocoon tree so I can upgrade Cocoon separately. Must use Apache to
> receive request. URL mapping has to be done per virtual host.
> 
> I looked at the FAQ, and followed the instructions. I rebuilt Apache with mod_rewrite
> enabled, then added the followed code to my httpd.conf:
> 
> <VirtualHost 	myhost.mydomain:80>
>     ServerName	      myhost.mydomain
>     DocumentRoot       /myhost.mydomain/htmls
> 
>     <IfModule mod_rewrite.c>
>         RewriteEngine on
>         RewriteLog /var/adm/www/rewrite.log
>         RewriteLogLevel 9
>         RewriteRule ^/xml /cocoon/xml/ [R]
>         RewriteRule ^/xml(.*) /cocoon/xml$1 [R]
>     </IfModule>
> 
>     WebAppConnection   conn      warp    myhost.mydomain:8008
>     WebAppDeploy       cocoon    conn    /cocoon
> </VirtualHost>
> 
> I also modified the Cocoon sitemap.xmap to forward the processing to a sitemap
> outside of the Cocoon tree.
> 
> This URL works:
> 
> http://myhost.mydomain/cocoon/xml/foo
> 	* Apache correctly passes the /cocoon/xml/foo address to 
>         Tomcat which then passes it to Cocoon. Output is correct
> 
> This URL 
>                  http://myhost.mydomain/xml/foo
> is redirected to http://myhost.mydomain/cocoon/xml/foo
> and the user sees it in the browser. Not what I wanted.
> I tried the single line [PT] variation shown in the FAQ, and 
> as indicated there, this does not work at all.
> 
> Thoughts?
> 
> Regards,
> --- Bob Bourdeau
> 
> ---------------------------------------------------------------------
> Please check that your question  has not already been answered in the
> FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>
> 
> To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>
> 
> 


-- 

Cocoon training, consulting & support
galatea.com



---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>


Mime
View raw message