bdelacretaz 2003/05/07 23:39:47
Modified: src/webapp sitemap.xmap src/webapp/stylesheets/system error2html.xslt Log: ResourceNotFound uses standard error page with different title Revision Changes Path 1.16 +4 -3 cocoon-2.1/src/webapp/sitemap.xmap Index: sitemap.xmap =================================================================== RCS file: /home/cvs/cocoon-2.1/src/webapp/sitemap.xmap,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- sitemap.xmap 8 May 2003 05:05:22 -0000 1.15 +++ sitemap.xmap 8 May 2003 06:39:47 -0000 1.16 @@ -520,9 +520,10 @@ <map:select type="exception"> <map:when test="not-found"> - <map:generate src="not-found.xml"/> - <map:transform src="welcome.xslt"> + <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:when> 1.6 +5 -2 cocoon-2.1/src/webapp/stylesheets/system/error2html.xslt Index: error2html.xslt =================================================================== RCS file: /home/cvs/cocoon-2.1/src/webapp/stylesheets/system/error2html.xslt,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- error2html.xslt 30 Mar 2003 12:48:32 -0000 1.5 +++ error2html.xslt 8 May 2003 06:39:47 -0000 1.6 @@ -8,11 +8,14 @@ <xsl:param name="contextPath" select="string('/cocoon')"/> +<!-- let sitemap override default page title --> +<xsl:param name="pageTitle" select="//error:notify/error:title"/> + <xsl:template match="error:notify"> <html> <head> <title> - <xsl:value-of select="error:title"/> + <xsl:value-of select="$pageTitle"/> </title> <link href="{$contextPath}/styles/main.css" type="text/css" rel="stylesheet"/> <style> @@ -24,7 +27,7 @@ <script src="{$contextPath}/scripts/main.js" type="text/javascript"/> </head> <body> - <h1><xsl:value-of select="error:title"/></h1> + <h1><xsl:value-of select="$pageTitle"/></h1> <p class="message"> <xsl:call-template name="returns2br">