I don't think I've ever used the XML helper, but this seems like a pretty simple array manipulation problem:
foreach ($data['news']['news_images'] as $newsImage) { $data['news'][] = $newsImage; } unset($data['news']['news_images']); On Jun 14, 3:57 am, Jankeesvw <jankee...@gmail.com> wrote: > Hi fellow Cake bakers! > > I have a question about the XML helper I have a model which has a > hasMany relationship. (News hasMany NewsImages). But when I use the > serialize function to render the data to XML I get a result I don't > really like. I would like cake to wrap a xml-node around the child > nodes of the images. Is this something that's possible? I really hope > so. > > I created a pastie with how the current XML looks and how I would like > it to look:http://www.pastie.org/1003646 > > Thanks a lot! > Jankees Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions. 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en