cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Colin Britton" <cbrit...@centervilletech.com>
Subject Re: [C2] Response logicsheet problem
Date Sat, 10 Mar 2001 02:15:45 GMT
Who is looking after the xsp-request logicsheet so I can get this patch
applied. I also have another one waiting at the office for the xsp-request
logicsheet which extends the objects it makes available which I will post
Monday.

rgds
CB

----- Original Message -----
From: "Colin Britton" <colin@freefoto.com>
To: <cocoon-dev@xml.apache.org>
Sent: Tuesday, March 06, 2001 11:46 AM
Subject: [C2] Response logicsheet problem


> The following XSP using the request and response logic sheets did not work
> due to an error in the response logicsheet. Here is the example and the
diff
> of the corrected logicsheet for someone to look at.
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <xsp:page
>           language="java"
>           xmlns:xsp="http://apache.org/xsp"
>           xmlns:xsp-request="http://apache.org/xsp/request"
>           xmlns:xsp-response="http://apache.org/xsp/response"
> >
>   <content>
>   <xsp-response:send-redirect>
>  <xsp-response:location><xsp-request:get-parameter
> name="U"/></xsp-response:location>
>   </xsp-response:send-redirect>
>
>   </content>
>
> </xsp:page>
>
> The logicsheet has the xsl following in it:
>
>  <xsl:template match="xsp-response:send-redirect">
>     <xsl:variable name="location">
>       <xsl:choose>
>         <xsl:when test="@location">"<xsl:value-of
> select="@location"/>"</xsl:when>
>         <xsl:when test="location">
>           <xsl:call-template name="get-nested-content">
>             <xsl:with-param name="content"
select="xsp-response:location"/>
>           </xsl:call-template>
>         </xsl:when>
>       </xsl:choose>
>     </xsl:variable>
>     <xsp:logic>
>       XSPResponseHelper.sendRedirect(response, <xsl:value-of
> select="$location"/>);
>     </xsp:logic>
>   </xsl:template>
>
> The <xsl:when test="location"> element should have the namespace prefix in
> order to match <xsl:with-param name="content"
> select="xsp-response:location"/>
>
> This error is also in the set-content-type and set-header elements in the
> response logicsheet.
>
> Logicsheet changes:
>
> cvs diff response.xsl (in directory
>
D:\xml_technology\C2\xml-cocoon\src\org\apache\cocoon\components\language\ma
> rkup\xsp\java\)
> Index: response.xsl
> ===================================================================
> RCS file:
>
/home/cvspublic/xml-cocoon/src/org/apache/cocoon/components/language/markup/
> xsp/java/Attic/response.xsl,v
> retrieving revision 1.1.2.7
> diff -r1.1.2.7 response.xsl
> 29c29
> < <xsl:when test="name">
> ---
> > <xsl:when test="xsp-response:name">
> 40c40
> < <xsl:when test="value">
> ---
> > <xsl:when test="xsp-response:value">
> 58c58
> < <xsl:when test="type">
> ---
> > <xsl:when test="xsp-response:type">
> 75c75
> < <xsl:when test="location">
> ---
> > <xsl:when test="xsp-response:location">
> *****CVS exited normally with code 1*****
>
> rgds
> CB
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
>
>


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


Mime
View raw message