i don't know how it works, i saw the code of cheeseCake but i still no
understand.

let me explain:

i have a YpItem model
        var $hasAndBelongsToMany = array('YpTag' =>
                array(
                        'className' => 'YpTag'
                )
        );


YpTag model

        var $hasAndBelongsToMany = array('YpItem' =>
                array(
                        'className' => 'YpItem'
                )
        );

i have 3 tables: yp_items, yp_tags, yp_items_yp_tags

here is the $this->data before $this->YpItem->save
Array
(
    [YpItem] => Array
        (
            [name] => dfgdfg
            [anonym] => 0
            [content] => dfgdfgfd
            [tags] => computer entertaiment pleasure
            [phone] => 0147933040
            [address] =>
            [zipcode] =>
            [city] =>
            [yp_category_id] => 61
            [user_id] => 1
        )

    [YpTag] => Array
        (
            [name] => Array
                (
                    [0] => 1
                    [1] => 2
                    [2] => 3
                )

        )

)

after save why my yp_items_yp_tags still empty.


On Mar 28, 6:50 am, "Dr. Tarique Sani" <[EMAIL PROTECTED]> wrote:
> On 3/27/07, davyke <[EMAIL PROTECTED]> wrote:
>
> > I found these Sql in cheeseCake when i edit a photo's tag, could you
> > explain where's the code for this?
>
> The SQLs are generated by CakePHP and not by Cheesecake - I just
> supply the array of tag IDs while saving the Photo
>
> HTH
> Tarique
>
> --
> =============================================================
> PHP for E-Biz:http://sanisoft.com
> Cheesecake-Photoblog needs you!:http://cheesecake-photoblog.org
> =============================================================


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