You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Fab Psycho <ps...@hotmail.com> on 2005/05/07 09:51:04 UTC

cforms with flow/jx/xsl

Tibor,

          Maybe I could use cforms instead of simple forms in my xsl.Is it 
possible to call a form template directly from xsl rather than having a 
sitemap entry for it or directly from my jx ?

I'm new in Cocoon and my approach may be wrong : I'm using an xsl to 
generate the site layout ; that xsl is linked to jx files with

<map:resources>
    <map:resource name="html">
      <map:transform src="stylesheet/main.xsl"/>
      <map:serialize type="html"/>
    </map:resource>
</map:resources>


<map:match pattern="static/*.jx">
   <map:generate src="static/{1}.jx" type="jx" label="debug"/>
   <map:call resource="html"/>
</map:match>

my jx receives data from my js flow file and xsl draws the stuff ... Where 
to place cform definition ?

Bests regards,
Fab

_________________________________________________________________



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


Re: cforms with flow/jx/xsl

Posted by oceatoon <t....@systheo.com>.
>     I do see what you mean but I don't find samples of cform generation in
> jx on the net :(
> On the other hand, is it impossible to declare (in main xsl)
Take any cforms sample (form1 for example),and change the generator to type
jx, and then you will be able to insert JX code inside your template file
retreiving whatever you from Flow and from CForms.
> 
> <xsl:template name="cformtemplate">
> and later in this file
> 
> <xsl:call-template name="cformtemplate" /> -> htmlize this one ...
Sorry I don't really understand what you mean??
Inside your template just put your ft:widget tags corresponding to your
definition, then you generate your template from this transformation and 
then go through a cforms generator you should have your form.

Regards
Tibor


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


Re: cforms with flow/jx/xsl

Posted by Fab Psycho <ps...@hotmail.com>.
Tibor,

    I do see what you mean but I don't find samples of cform generation in 
jx on the net :(
On the other hand, is it impossible to declare (in main xsl)

<xsl:template name="cformtemplate">
and later in this file

<xsl:call-template name="cformtemplate" /> -> htmlize this one ...

Regards,
Fab

_________________________________________________________________



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


Re: cforms with flow/jx/xsl

Posted by oceatoon <t....@systheo.com>.
> Maybe I could use cforms instead of simple forms in my xsl.Is it
> possible to call a form template directly from xsl rather than having a
> sitemap entry for it or directly from my jx ?
I don't know exactly what you do in your main.xsl but if you really want to
keep this structure you have to generate your form document meaning that in
your xsl you simply generate whtever you want from your cforms definition.
And then you pass that newly generated file into a CForms generator.
> 
> I'm new in Cocoon and my approach may be wrong : I'm using an xsl to
> generate the site layout ; that xsl is linked to jx files with
> 
> <map:resources>
>     <map:resource name="html">
>       <map:transform src="stylesheet/main.xsl"/>
>       <map:serialize type="html"/>
>     </map:resource>
> </map:resources>
> 
> 
> <map:match pattern="static/*.jx">
>    <map:generate src="static/{1}.jx" type="jx" label="debug"/>
>    <map:call resource="html"/>
> </map:match>
> 
> my jx receives data from my js flow file and xsl draws the stuff ... Where
> to place cform definition ?
This is just an idea : 
you could put what you are doing (drawing) in main.xsl into a
myformtemplate.jx file and call your JX file directly from Flow  meaning
you would have saved one pipeline. the jx generator also does cforms
generating. Hope this was clear.

Tibor


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