cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kirchhoff, Lars" <Lars.Kirchh...@wincor-nixdorf.com>
Subject AW: How to get back XMLForm data to Cocoon
Date Thu, 09 Jan 2003 02:01:51 GMT
hello sylvain,

I'm using the page parameter, which is returned from the action 
class to separate the stylesheets for the forms and the one for 
the actual output. Below an example of the sitemap.

------ code ----------------------------
<map:select type="parameter">
  <map:parameter name="parameter-selector-test" value="{page}" />
        
  <map:when test="output">
    <map:call resource="format-transformation">
      <map:parameter name="format" value="{format}" />
    </map:call>        
  </map:when>
      
  <map:otherwise>
    <map:transform src="stylesheets/wizard2html.xsl" />   
    <map:transform src="stylesheets/xmlform2html.xsl" />
    <map:serialize type="xml" label="debug"/>  
  </map:otherwise>
</map:select>       
------ /code ----------------------------

to have different formats to be used I returned another parameter 
from the action called format, which is a databean property and 
can be choosen in one of my forms. 

Instead of return page( VIEW_SOMETHING ), I do the following:

------ code ----------------------------
Map sitemapParams = new HashMap();
 
... some code .....

sitemapParams.put( "page", VIEW_SOMETHING );

sitemapParams.put( "format", jBean.getFormat() );

return sitemapParams;	
------ /code ----------------------------

ciao Lars


> -----Urspr√ľngliche Nachricht-----
> Von: Sylvain.Thevoz@swisscom.com [mailto:Sylvain.Thevoz@swisscom.com]
> Gesendet: Mittwoch, 8. Januar 2003 22:06
> An: cocoon-users@xml.apache.org
> Betreff: How to get back XMLForm data to Cocoon
> 
> 
> Hello,
> 
> I'm using XMLForm to collect information.
> With these information I retrieve a result from a database 
> (with Java code in the Action file).
> 
> Now I want to take this result to display it on the screen. 
> And I want to use the Cocoon publication features.
> 
> My question is: how to get back this result to display it with Cocoon?
> 
> 
> Thank you
> Sylvain
> 
> ---------------------------------------------------------------------
> 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>
> 

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