for the controller aspect it does not change anything posting data
using ajax or not. The data posted are accessible in the same way
($this->params['data']['Controller'] .. for example).
The same approach for the rendering. Now everything resides into which
parts of the view you update with you ajax call (basically doing ajax
will not affect your controller code). The difference wiht ajax
resides into the view (thtml ot tcp).

On Jun 16, 8:47 pm, varunkrish <[EMAIL PROTECTED]> wrote:
> <?php echo $ajax->form(array('action'=>$html->url('edit')))?>
>
> <div id="editAll" style="display:none">Loading..<?php echo 
> $html->image('spinner.gif',array('alt'=>'Saving..','id'=>'editAllimg'))?>
>
> </div>
>
> <?php print $ajax->submit('Load Post', array('url' =>
> 'editAll/','update'=>'posts','frequency'=>'2','loading'=>"Element.show('editAll');",'loaded'=>"Element.hide('editAll');"));?
>
>
>
> I have a view for add post , but i have text input for edit post . if
> i type a post id in the edit post and give read.. the form contents
> should be populated via ajax ?
>
> my doubt is i know how to save data (add or edit) via ajax by sending
> data to the controller
>
> but how to get back data from the controller and populate form
> contents ?


--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to