Saturday, January 3, 2009

Re: Edit multiple models in the same page: possible?

Use Ajax?

On Jan 3, 4:07 pm, Jaime <ja...@iteisa.com> wrote:
> Hi all,
>
> I wonder if it's possible to have two different forms for two
> different (but related) models in the same page.
>
> Imagine a page where the logged in user can edit his profile (model
> Profile) as well as to add a photo into his gallery (model Image).
>
> <?php echo $form->create('Profile'); ?>
> ...
>
> <?php echo $form->create('Image'); ?>
> ...
>
> The problem here is that after submiting one of the forms, the user is
> redirected to /model/edit/, and not back to the current page.
>
> I cannot imagine how to fit both forms in the same page without
> loosing the validationErrors info.
>
> Any clue?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: