Just use appropriate selector: http://xml.apache.org/cocoon/userdocs/selectors/selectors.html
Artur... > -----Original Message----- > From: Josema Alonso [mailto:alonso@;aafunky.com] > Sent: November 4, 2002 11:39 AM > To: Cocoon-Users > Subject: dynamically choosing an action at runtime > > > Hello, all. > > Is it possible to choose what an action perform at runtime > based on sitemap > parameters? I have the pipeline below for processing > XMLForms. It is working > just nice for one form if I do not use the {1} param but hard code the > Action name. I would like to make it work as described so I could > dynamically choose what actions to apply to every form based > on parameter. > > Any ideas? > > thanks > > ---------------------------------------------- > <!-- XMLForms pipeline --> > <map:pipeline> > <map:match pattern="*"> > <map:act type="{1}Action"> > <!-- XMLForm parameters for the AbstractXMLFormAction --> > <map:parameter name="xmlform-validator-schema-ns" > value="http://www.ascc.net/xml/schematron"/> > <map:parameter name="xmlform-validator-schema" > value="schematron/equipment-type-sch-report.xml"/> > <map:parameter name="xmlform-id" value="form-insert"/> > <map:parameter name="xmlform-scope" value="session"/> > <map:parameter name="xmlform-model" > value="net.josema.xmtrader.forms.xmldb.recordings.equipment.{1}Bean"/> > <!-- original XMLForm document --> > <map:generate src="{page}.xml"/> > <!-- populating the document with model instance data --> > <map:transform type="xmlform" label="debug, xml"/> > <!-- personalizing the look and feel of the form controls --> > <map:transform src="styles/wizard2html.xsl"/> > <!-- Transforming the XMLForm controls to HTML controls --> > <map:transform src="styles/xmlform2html.xsl"/> > <!-- sending the HTML back to the browser --> > <map:serialize type="html"/> > </map:act> > </map:match> > </map:pipeline> > > > > --------------------------------------------------------------------- > 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: <[EMAIL PROTECTED]> > For additional commands, e-mail: <[EMAIL PROTECTED]> > --------------------------------------------------------------------- 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: <[EMAIL PROTECTED]> For additional commands, e-mail: <[EMAIL PROTECTED]>