You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Sylvain Wallez <sy...@anyware-tech.com> on 2002/06/24 22:51:53 UTC

[announce] Extended sitemap variable substitution syntax

Hi team,

The extended sitemap variable substitution syntax based on InputModules 
is available in HEAD.

Sitemap variables can now be prefixed by the name of an InputModule. 
This means for example that "{request:foo}" will evaluate to the value 
of the "foo" request parameter or that "{session:myAttr}" will evaluate 
to the value of the "myAttr" session attribute.

Unprefixed variables are sitemap variables as usual, but there's also a 
reserved "sitemap" prefix. This means that "{../1}" is equivalent to 
"{sitemap:../1}". This can be used when the name of a sitemap variable 
contains a colon, e.g. "{sitemap:the:name}"

For background info on this, see the proposal and vote at :
http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=102224876231373
http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=102274954212137

Tests weren't extensive but this seems to work well.

                                  --o0o--

This new feature means that InputModules will be more widely used, and 
therefore I'd like to propose some changes in the names they have in the 
current cocoon.xconf to more meaningfull ones :
- "request-param" instead of "request" for request parameters,
- "request-header" instead of "header" for request headers,
- "request-attr" instead of "attribute" for request attributes,
- "session-attr" instead of "session" for session attributes.

Thoughts ?

Sylvain

-- 
Sylvain Wallez
 Anyware Technologies                  Apache Cocoon
 http://www.anyware-tech.com           mailto:sylvain@apache.org



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


Re: [announce] Extended sitemap variable substitution syntax

Posted by Christian Haul <ha...@dvs1.informatik.tu-darmstadt.de>.
On 24.Jun.2002 -- 10:51 PM, Sylvain Wallez wrote:
> Hi team,
> 
> The extended sitemap variable substitution syntax based on InputModules 
> is available in HEAD.

Darn, you beat me by half a class! :-) But this way I have at least
understood by and large how the treeprocessor works. Great!

> This new feature means that InputModules will be more widely used, and 
> therefore I'd like to propose some changes in the names they have in the 
> current cocoon.xconf to more meaningfull ones :
> - "request-param" instead of "request" for request parameters,
> - "request-header" instead of "header" for request headers,
> - "request-attr" instead of "attribute" for request attributes,
> - "session-attr" instead of "session" for session attributes.
> 
> Thoughts ?

IMHO the suggested names are too verbose. And since there is e.g. only
the request header confusion is unlikely.

	Chris.

-- 
C h r i s t i a n       H a u l
haul@informatik.tu-darmstadt.de
    fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08

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