cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jens Maukisch <coc...@maukisch.net>
Subject Re[6]: Object list form ?
Date Mon, 02 May 2005 21:15:28 GMT
Hi Sebastien,

> But the problem with this is how do I get data back from "users-list"
> form page ? How to get POST parameters ?
> And over all, which solution is more elegant : CForm (if possible) or
> ordinary HTML form ?
> WDYT ?

We've used CForms for this.

function displayUsers(){
  var users = usersService.findAllUsers();
  var form = new Form("model.xml");
  form.createBinding("binding.xml");
  form.load(users);
  form.showForm("displayUsersForm");
  // get the repeater widget from the form an look which
  // users are selected and get the corresponding bean
  // from the users collection and do whatever you want to do :-)
  // maybe dependend on form.submitId
}

In the form-model you can use a fd:booleanfield for the selection
and fd:output-fields to display the username inside the
repeater-widget.

hth

-- 
* best regards
* Jens Maukisch              


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message