Friday, September 24, 2010

Re: HABTM retrieve data


emm...u mean to display for input select type?

if it is so...then do this:

{{{

$result = $this->Subscriber->Distributer->find("list");
$this->set(compact('result'));

}}}

 //and then in view 

{{{

print $form->input("Distributer"); //will create a multiple select :D

}}}

--
Tilen Majerle


2010/9/25 Avinash <avibangar@gmail.com>
I have two models subscribers and distribution list, the relation
between them is HABTM, now some subscribers are associated with the
distribution list. I'm giving an option of adding more subscribers to
a distribution list, now i want to display list of subscribers which
are not associated to that distribution list

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 cake-php@googlegroups.com
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?hl=en

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 cake-php@googlegroups.com
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?hl=en

No comments: