Where is the bind() statement? Most of my code looks like this:

        $this->form->bind($submittedValuesArray, $request->getFiles
('sf_guard_user_profile'));
        if ($this->form->isValid())

When in doubt, put $submittedValuesArray in print_r() and see what you
really have.


On Sep 24, 6:34 am, johnnygri <[email protected]> wrote:
> Hi there, I'm replacing the processForm() method in the sfGuardUser
> Doctrine admin generator module. We have:
>
> if($form->isValid())
> {
>             $sf_guard_user = $form->save();
>
>             // I've added this next line, you'll see why
>             $sf_guard_user->reloadGroupsAndPermissions();
>
>             // and some veeery basic debugging:
>             print_r($sf_guard_user->groups->toArray());
>             exit;
>
> }
>
> When I add a new user and select one or more groups, it is
> successfully saved with the relations, viewing the DB or simply
> listing in admin generator proves this. I cannot figure out for the
> life of me however why the above outputs: Array() - it shouldn't be
> empty at this point should it, especially after I've 'forced' a reload
> of groups and permissions relations? I need access to this new user's
> selected groups so I can decide whether to raise a specific event or
> not.
>
> Thanks for any help in advance,
> John
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"symfony users" 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/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to