Yes you can. I defined my Cocoon2 settings to take "_images" as a relative
link, which I place in my "tomcat\webapps\cocoon\xmlimages" directory. The
"images/**.gif" definition is there by default.

In the sitemap.xmap file, look for the following:
   <map:match pattern="images/**.gif">
    <map:read src="resources/images/{1}.gif" mime-type="image/gif"/>
   </map:match>
   
   <map:match pattern="_images/**.gif">
    <map:read src="xmlimages/{1}.gif" mime-type="image/gif"/>
   </map:match>   

   <map:match pattern="_images/**.jpg">
    <map:read src="xmlimages/{1}.jpg" mime-type="image/jpg"/>
   </map:match>
   
   
   <map:match pattern="images/**.jpg">
    <map:read src="resources/images/{1}.jpg" mime-type="image/jpg"/>
   </map:match>

   <map:match pattern="images/**.png">
    <map:read src="resources/images/{1}.png" mime-type="image/png"/>
   </map:match>

Hope this helps.

-----Original Message-----
From: Fiore, Francois [mailto:[EMAIL PROTECTED]]
Sent: August 3, 2001 9:50 AM
To: '[EMAIL PROTECTED]'
Subject: relative links



Hi everyone !

I am using cocoon to transform a JSP page formatted as an XML page to html
using an XSL stylesheet.Everything is fine except that in the XSL page I
have some relative links to pictures which don't work. I checked to put the
pictures in the right directory.
This is quite surprising because in the XSL page I also put a form with a
relative link as "action" to the jsp page itself and it works ok.

Have I not set up everything correctly for getting the images ???

 Can't we use relative links ???

I am a bit confused !!

thanks for your help 

Hope this question is not too stupid cause I've got the feeling I am missing
something ...

francois


--
This communication contains confidential information intended solely for the
use of the individual/s and/or entity or entities to whom it was intended to
be addressed.  If you are not the intended recipient, be aware that any
disclosure, copying, distribution, or use of the contents of this
transmission is prohibited.  If you have received this communication in
error, please contact the sender immediately, delete this communication from
your system, and do not disclose its contents to any third party, or use its
contents.  Any opinions expressed are solely those of the author and do not
necessarily represent those of Orchestream Ltd or its group of companies
unless otherwise specifically stated.

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

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

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

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to