You've just got your array wrong - it should have the assocation name
as the key, and the attributes array as the value.  You've got it
right for the "File" association, but then you've got the "Category"
association in another array.

var $hasAndBelongsToMany = array(
        'File' => array(
                'className' => 'File',
                'joinTable'    => 'files_items',
                'foreignKey'   => 'item_id',
                'associationForeignKey'=> 'file_id',
                'conditions'   => '',
                'order'        => '',
                'limit'        => '',
                'unique'       => true,
                'finderQuery'  => '',
                'deleteQuery'  => '',
        ),
        'Category' => array(
                'className' => 'Category',
                'joinTable'    => 'categories_items',
                'foreignKey'   => 'item_id',
                'associationForeignKey'=> 'category_id',
                'conditions'   => '',
                'order'        => '',
                'limit'        => '',
                'unique'       => true,
                'finderQuery'  => '',
                'deleteQuery'  => '',
        )
);


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