>From what I understand,
HTML helper explodes the input name by slash, and takes the first one as model and second one as field name. The rest of the name is ignored.
Then make the onput tag by
<input name="data[%s][%s]" %s/>
where first %s is model name, second is field name, and the last one is the rest of attributes.
I've seen and used the hack to do exactly what you want to do by using the name as
'Person/Address][address1'
This makes the field name as "Address][address1" and the name in output tag would be
"data[Person][Address][address1]"
Also, you can fix the setFormTag function in HTML helper by this person's patch
https://trac.cakephp.org/ticket/945
Still, HTML helper will make id as something like "Person[Address][Address1", so you still might want to specify it, or make a new helper.
Hope this helps.
Sohei
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---
- Re: Composit forms for composit models Sohei Okamoto
- Re: Composit forms for composit models Stuart
- Re: Composit forms for composit models Sohei Okamoto
