I'm currently working on an "in between" solution. It's for a big hospital foundation. They need different forms for online donations, subscription to activities, other requests, etc. They supplied me about 10 different examples of form they would like to be able to customize.
I decomposed each form element in "form element" linked to a model and a controller (for example, all forms have a similar "client_identification" part that is linked to the client controller and model). Another example is a "donation_info" form element that is linked to the donation model and controller. So it's a not a fully customizable dynamic form creator, the form must be "assembled" out of pre defined elements and they can also add some custom fields. I created a module that let the managers create new forms out of the element, another one to assemble and display the form to the end user. I found a way (using session variable) to save the data in multiple model and keep the validation information for each. I'm currently working on a simple workflow module that will let the manager define the role of their employees and the "routing" for each type of form. If I was working on a "survey creator", I would use the same strategy, with a "form element" for each type of questions and the content of the question as parameters. For a fully customizable dynamic form system, allowing the users to create their models would be a solution, the only problem I see is how to store that data afterward. Do you want to create a different table for each user defined form ? Otherwise, you would need to bypass the model -> database and create a novel way to take the form data based on that model and save it in a different way. On Jan 20, 6:57 am, "R. Rajesh Jeba Anbiah" <[EMAIL PROTECTED]> wrote: > On Jan 20, 9:13 am, Baz <[EMAIL PROTECTED]> wrote: > > > I guess I'm misunderstanding also, but what was the problem with > > $form->inputs()? > > > If your using that database, that means model. $form->inputs() dumps inputs > > for all the form fields. > > The situation is more of like allowing the users to create models; > the users define fields, rules/validations, labels, etc > > -- > <?php echo 'Just another PHP saint'; ?> > Email: rrjanbiah-at-Y!com Blog:http://rajeshanbiah.blogspot.com/ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
