cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Johannes Koch <k...@pixelpark.com>
Subject Re: requests with document function
Date Fri, 21 Jun 2002 12:17:36 GMT
Johannes Koch wrote:
> Cocoon 2.0.2/Tomcat 4.0.1/Java1.3.1_01
> In an XSLT stylesheet I have the following template:
> 
> <xsl:template match="foo">
>   <xsl:variable name="bar" 
> select="document('http://www.xyz.org/bla.xml')/fasel"/>
>   <xsl:variable name="hasGrmpf" select="boolean($bar/grmpf)"/>
>   <xsl:apply-templates select="$bar/grmpf"/>
>   ...
> </xsl:template>
> 
> The template is called only once.
> 
> According to the server log, this results in 5 GET requests for 'bla.xml':
> 2 for $bar, 2 for $hasGrmpf and 1 for apply-templates.

Correction: 6 GET requests:
2 for $bar, 3 for $hasGrmpf and 1 for apply-templates.

If I change the template to
   <xsl:variable name="hasGrmpf" select="boolean($bar)"/>
(without the '/grmpf'), I have 4 requests.

I would have expected to have only one request (for the document
function). Can somebody explain the six requests?

-- 
Johannes Koch  . IT Developer
Pixelpark AG   . http://www.pixelpark.com
Rotherstra├če 8 . 10245 Berlin  .  Germany
phone: +49 30 5058 - 1288  .  fax: - 1355


---------------------------------------------------------------------
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