You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Michael Ralston <mi...@ralston.id.au> on 2006/07/04 02:16:54 UTC
Re: content managed dynamic cforms
Toby wrote:
> Michael Ralston wrote:
>
>> It looks like you've basically hard coded your fields into the
>> flowscript. This is what I wanted to avoid.
>>
>
> Can't you just iterate over the fields with plain javascript?
>
I ended up doing it with javaflow with the following...
in my flow:
mailer.setForm(form.getModel());
inside mailer:
public void setForm(Widget widget) {
for (Iterator<Widget> i = ((Form)widget).getChildren();
i.hasNext();) {
Widget w = i.next();
String key = w.getFullName();
String value = w.getValue().toString();
map.put(key, value);
}
}
Michael R
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org