You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Olivier Billard <ob...@rennes.jouve.fr> on 2004/03/02 16:16:47 UTC

[Portal] How to display cocoon errors in a coplet ?

Hi all !

I use the portal for a project and i'm not able to display errors in a (main) coplet.
I always have a blank content, as if when rendering the content of the coplet, the error 
content is not put in the whole portal page.

I tried xml-serializing, html-serializing errors :

     <map:handle-errors>
       <map:select type="exception">

         <map:when test="not-found">
           <map:generate type="notifying"/>
           <map:transform src="stylesheets/system/error2html.xslt">
             <map:parameter name="contextPath" value="{request:contextPath}"/>
             <map:parameter name="pageTitle" value="Resource not found"/>
           </map:transform>
           <map:serialize status-code="404"/>
         </map:when>

         <map:when test="invalid-continuation">
           <map:generate src="not-found.xml"/>
           <map:transform src="welcome.xslt">
             <map:parameter name="contextPath" value="{request:contextPath}"/>
           </map:transform>
           <map:serialize status-code="404"/>
         </map:when>

         <map:otherwise>
           <map:generate type="notifying"/>
           <map:transform src="stylesheets/system/error2html.xslt">
             <map:parameter name="contextPath" value="{request:contextPath}"/>
           </map:transform>
           <!--map:serialize status-code="500"/-->
--->      <map:serialize type="html"/>
         </map:otherwise>
       </map:select>

     </map:handle-errors>

(map:otherwise is choosen, i tried renaming the transformer src attribute)

But no way : I have no content in the coplet...
I can right display the error when calling the coplet pipe, but it' empty in the portal 
page...

Can anyone show me the light ?
Thank in advance

-- 
Olivier BILLARD


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