On Nov 26, 2:46 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:
> Hi all
>
> I'm a totally beginner with CakePHP and need some help.
>
> I have a user list with pagination, who shows me all users. It works
> fine. But, all users are in different usergroups, and I like to have a
> select-box, where I can choose one of the usergroups. After that, it
> should show me all users who are in the selected group.
>
> 1. How can I list all usergroups in the Users-Controller?
> 2. How can Ifilterthe user list with the selected usergroup?
>
> Thank you very much and sorry for my bad english. =)
I may be completely wrong about this, as I've only been using Cake for
a few days myself, but I did find this tutorial on pagination -
http://bakery.cakephp.org/articles/view/basic-pagination-overview-3 -
which lead me to this solution :-
$this->set('Secmatrixs', $this-
>paginate('Secmatrix',array("`Secmatrix`.`pubid` = `3`")));
Notice the array() on the end which is basically a 'WHERE' clause in
the pagination select statement.
I'm looking for a more sophisticated way of doing this, but this works
for now.
Rob.
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---