I found the solution:
http://groups.google.com/group/cake-php/browse_thread/thread/b2a252afd5968a4d

I had looked at many other types of solutions with afterSave and
"with". They didn't make sense. But this one is clean and simple.

On Jun 17, 11:52 pm, Madis <[email protected]> wrote:
> I have the following problem. I see that it has been addressed on many
> pages but I still have not yet found an answer for this.
> How would it be possible to save additional data fields? Right now
> cake treats both fields as linking ID's.
>
> "7 - HABTM with additional attributes
> I'd love to see an example of HABTM with additional attributes for
> CakePHP 1.2.8004.
>
> For the sake of an example to work with, lets take the Recipe/Tags
> example and add a "weighting" attribute to the join table. This would
> allow a particular Tag for a Recipe to be weighted for the purposes
> of.. well, search relevancy. Weighting would be an integer.
>
> The particular example I'd like to see is when a user is maintaining a
> Recipe. Even though the Recipe has Tags, and each of those joins has a
> weighting, how does one code the form and the controller so that all
> the join information maintained between saves (given that _saveMulti
> like to delete the contents of the join table before adding it back in
> again)."
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" 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