The qestion is Ajax-specific, because when first assigning html to variable then echoing it - will not work with Ajax feature.
simple code example from some imaginary view (*.ctp) out: when page rendered, this example works fine: someview.ctp . .. ... echo $ajax->div('dynamic1'); echo "<h2><span>".$data1."</span></h2>"); echo $ajax->divEnd('dynamic1'); ... .. . but if doing like this: . .. ... $a1=$ajax->div('dynamic1'); $a2="<h2><span>".$data1."</span></h2>"); $a3=$ajax->divEnd('dynamic1'); echo $a1; echo $a2; echo $a3; /// or $html=$a1.$a2.$a3; echo $html; ... .. . this will not work - or - it works only the first time - but after the first Ajax request, the dynamic html replacement gives blank/wrong results. do anybody knows why this happens ? because from the php perspective both examples have same functionality. --~--~---------~--~----~------------~-------~--~----~ 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 to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---