Simple scenario:
Top div contains ajaxed, paginated index of items. Bottom div shows /
view when an item is selected from the index. You can choose to edit
the item in the bottom div, it ajaxes in the /edit form. On
susccessful submit, you redirect back to /view with flash saying
'Saved OK'.
Could you do the same with a setAction() inside the controller?
(assuming it's the same controller)
Adam
On Nov 6, 6:54 am, jasonL [EMAIL PROTECTED] wrote:
Simple scenario:
Top div contains ajaxed, paginated index of items. Bottom div shows /
view when an item is selected from the index.
I just upgraded to RC3 and ran into this exact problem. I've not
found any way to get a layout to render after an Ajax redirect, except
by not using RequestHandler. Did you find a solution?
-Jason
On Oct 14, 3:33 pm, Julián Lastiri [EMAIL PROTECTED] wrote:
Well, i found that when i
Why do you need to redirect inside an ajax request? I've never run
into this requirement before.
Cheers,
Adam
On Oct 15, 6:33 am, Julián Lastiri [EMAIL PROTECTED] wrote:
Well, i found that when i call redirect from an ajax request the
redirect is forwarded to the beforeRedirect method from
When i use redirect from an ajax request the ajax.ctp is not rendered.
I try calling setFlash with growl layout but doesn't work.
I have a content div in my webpage. When i submit the form i save the
data, then set a Flash message and redirect to the index.
The index is loaded in the content
Well, i found that when i call redirect from an ajax request the
redirect is forwarded to the beforeRedirect method from RequestHandler
Component. This
method calls requestAction which sets bare in 1 and the dispatchers
does the following
if (!empty($this-params['bare'])) {
I'm using cakephp 1.2RC3
I want to show messages with setFlash method but when i use redirect
the ajax.ctp layout is not rendered.
I'm using this code to show messages with jGrowl inside my ajax.ctp
layout
?php if ($session-check('Message.flash')): ?
script
jQuery(document).ready(function(){
Lastiri
Sent: Monday, October 13, 2008 2:11 PM
To: CakePHP
Subject: Ajax Redirect and setFlash Messages
I'm using cakephp 1.2RC3
I want to show messages with setFlash method but when i use redirect
the ajax.ctp layout is not rendered.
I'm using this code to show messages with jGrowl inside my ajax.ctp
-Original Message-
From: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf
Of Julián Lastiri
Sent: Monday, October 13, 2008 2:11 PM
To: CakePHP
Subject: Ajax Redirect and setFlash Messages
I'm using cakephp 1.2RC3
I want to show messages with setFlash method but when i use
how do I redirect inside of an ajax request?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email
10 matches
Mail list logo