El mar, 15-02-2005 a las 18:13, Linden H van der (MI) escribi�:
<snip/>
> This sounds as if you have not included the <jx:set> statements in the proper 
> tags:
> 
> <jx:template xmlns:jx="http://apache.org/cocoon/templates/jx/1.0";>
>  <jx:set var="user" value="007"/>
>  ....
> </jx:template>
> 

I actually have 
<zip:archive xmlns:zip="http://apache.org/cocoon/zip-archive/1.0"; 
  xmlns:jx="http://apache.org/cocoon/templates/jx/1.0";
  xmlns:session="http://apache.org/cocoon/session/1.0";>

in the head of the document.

I did not include it in a jx:template though, but I got it working as
follow:

<!--DEBUG 
    Variables, that actual have to come from the flow-->
  <jx:set var="user">1736</jx:set>
  <jx:set var="doc">kk</jx:set>
  
  <!--Marco that creates the dynamic attachments4zip-->
  <jx:macro name="attachments4zip">
          <jx:parameter name="user"/>
    <jx:parameter name="doc" />
    <zip:entry name="userdata.html"
src="../content/users/#{$user}/#{$doc}.xml"/>
    <!--<test2>user:${user}
      doc:${doc}</test2>-->
        </jx:macro>
  
  <attachments4zip user="#{$user}" doc="#{$doc}"/>

Will return:
<zip:entry name="userdata.html" src="../content/users/1736/kk.xml"/>

BUT as soon as I change the user var to 
<jx:set var="user"><session:getxml context="authentication"
path="/authentication/data/User/VfNumber"/></jx:set>

It is failing, I have to test what happends if I pass the values from
the flow.

Cheers for your time. 

IMO the behaviour of jx is not really intuitiv, I ended up doing an
extensive trail 'n error session to get it working. :(

The different usage of #{var}, #{$var} and ${var} do not make life
easier either. I really do not know when to use which type.

salu2
thorsten

> HTH.
> 
> Bye, Helma
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
-- 
thorsten

"Together we stand, divided we fall!" 
Hey you (Pink Floyd)


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to