Start by reading and trying out the examples given at http://book.cakephp.org/view/1341/Basic-Usage
It has all the details you need OR better start by understanding what a Binary tree is http://en.wikipedia.org/wiki/Binary_tree
Cheers
Tarique
On Mon, Jan 31, 2011 at 4:18 PM, fadhli <e.fadhli@gmail.com> wrote:
hi Mr Tariquei use tree only for category. and menu,1, id2, parent_id,3 name,i realy stuck to make binary treehttp://book.cakephp.org/view/1339/Tree said To use the tree behavior, your database table needs 3 fields as listed below (all are ints):
- parent - default fieldname is parent_id, to store the id of the parent object
- left - default fieldname is lft, to store the lft value of the current row.
- right - default fieldname is rght, to store the rght value of the current row.
my question.
1. how to generate this table look like pine tree? look like this imange http://petemontgomery.files.wordpress.com/2009/05/binarytree1.jpg?w=333&h=299
2. how to decide leftnode or rightnode?
and.
3. how to insert data to this tree
On Mon, Jan 31, 2011 at 4:52 PM, Dr. Tarique Sani <tariquesani@gmail.com> wrote:
--If you know how to make a tree then make one where every node has just two (or less) child nodes you will end up with a binary tree.....
Cheers
TariqueOn Mon, Jan 31, 2011 at 3:07 PM, fadh <e.fadhli@gmail.com> wrote:
hallo baker
how to create binary tree in cakephp.
i only know how to create tree, not a binary tree.
thanks.
--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
--
=============================================================
Cheesecake-Photoblog: http://cheesecake-photoblog.org
PHP for E-Biz: http://sanisoft.com
=============================================================Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
--
=============================================================
Cheesecake-Photoblog: http://cheesecake-photoblog.org
PHP for E-Biz: http://sanisoft.com
=============================================================
--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
No comments:
Post a Comment