cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Reinhard Poetz <>
Subject CForms Wizards
Date Fri, 12 Nov 2004 20:56:34 GMT
Sylvain Wallez wrote:
> Sylvain Wallez wrote:
>> Sorry to rain on the party, but the new widget state stuff in CForms 
>> should make building multi-page forms a piece of cake.
>> Off writing an example....
> Done, I wrote my first wizard with CForms :-)
> Please update branch 2.1.x and point your browser to 
> http://localhost:8888/forms-samples/do-multipage.flow
> Enjoy!

Great, thanks for the example! One question: IIUC the wizard is driven by the 
widget states and the event handling mechanism. This may solve many use cases 
but would it be possible to control which part of the form is shown by the 
controller (flowscript) which would bring some more flexibility (mix in 
non-forms pages, jump to different sub-pages)?

[some pseudocode ...]
var myFlow() {
   var form = new Form("myForm");
   form.showSubForm("myPipeline", "../page1");
   form.showSubForm("myPipeline", "../page");;

And while writing this, another question came up: What's the best way to deal 
with validation errors? example: On page 2 the users enters something that 
wouldn't let page 1 validate any more. Can we handle this?


View raw message