hi,i'm still newbie in cakePHP
i have a problem to populate my data into combobox.
i have one table named Category which have function to manage account
(in finance) and sub account..
the logic are account have many sub account, sub account have many
child..the field of the table represented in followings :
id                  ------->id of the account data
parent_id       ------->id parent of the account data
name            ------->name of the account
when i want to make a new account (it can account,sub account and
child) i want to select the parent of that account..it will get from
field id..
i tried to write the followings script into the controller :

function categoryParent(){
                $parentinfo = $this->Category-
>find('list',array('fields'=>array('Category.id','Category.name')));
                $this->set('idparent',$parentinfo);
}

but i still dont know how to call the variable "idparent" in "add"
view...so i can populate all "id" (not parent_id) in combobox..
can sombody help me to solve this problem?

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

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