Without any info on how you store the messages, my guess is: $c = new Criteria(); $c->add(MessagePeer::USER_ID, $this->getUser()->getId()); return MessagePeer::doSelect($c);
On Wed, Nov 25, 2009 at 13:45, tirengarfio <tirengar...@gmail.com> wrote: > Hi, > > as many of you have guessed im making a little social network. > > Now i need to fetch the messages of the user receives from other > members of the social network. > > The line below access to the first message sent to the user: > > $this->getUser()->getGuardUser()->getMessage(); > > but.....Is there any way to fetch ALL the messages sent to the user?? > > I have tried with getMessageS(), or writting that line inside a loop > but it doesnt work...:) > > > Bye > > Javi > > > -- > > You received this message because you are subscribed to the Google Groups > "symfony users" group. > To post to this group, send email to symfony-us...@googlegroups.com. > To unsubscribe from this group, send email to > symfony-users+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/symfony-users?hl=en. > > > -- You received this message because you are subscribed to the Google Groups "symfony users" group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.