Re: Highlight Author Comment
Never MInd Figure it out thank you '; }else{ echo''; } ?> On Sep 19, 7:42 am, Simon wrote: > Thanks for the reply I'm confuesd here my post table dosent got > user_Id user don't have to login and post the only thing the login to > comment now here is I give full details > > User hasMany comments > comment belongs to user > > Post hasMany comments > comments belongs to post > > Now here's my comment table structure > > Id > user_id > post_id > comment > active > created > > here's user table structure > id > username > firstname > lastname > group = default is user > email > created > > here is my post > > id > comment_id > content > comment_count > created > modified > > And I made function in my post controller > called function comment() > > So when some one comment it's like > > post/comment/1234 > > I hope this help you slove my problem thank you all > > On Sep 19, 4:54 am, "j0n4s.h4rtm...@googlemail.com" > > > > wrote: > > Use cake bake. On the output of cake bakes comments/index.ctp find the > > table loop and within that table loop you have to do that comparison > > like $post['Post']['user_id'] == $comment['Comment']['author_id'] > > > On Sep 18, 3:29 pm, Simon wrote: > > > > is there sombody help here please thank you im really waiting for > > > someone to help here > > > > > > if($this->$comment['User'[['Group']['admin']){ > > > echo''; > > > echo $comment['Comment']['comment']; > > > echo''; > > > > }else{ > > > > echo' > > > echo $comment['Comment']['comment']; > > > echo''; > > > > } > > > > ?> > > > > On Sep 17, 1:24 pm, Simon wrote: > > > > > thank you for this can i do it this way correct me if i'm worng > > > > > > > > if($this->$comment['User'[['Group']['admin']){ > > > > echo''; > > > > echo $comment['Comment']['comment']; > > > > echo'';}else{ > > > > > echo' > > > > echo $comment['Comment']['comment']; > > > > echo'';} > > > > > ?> > > > > > On Sep 17, 1:00 pm, Pablo Viojo wrote: > > > > > > Something like this: > > > > > > > > > > if ($post['Post']['user_id']==$comment['Comment']['user_id']){ > > > > > $commentClass='author';} else { > > > > > > $commentClass='non-author';} > > > > > > ?> > > > > > > > > > > > Change your variable names appropiately. > > > > > > Regards, > > > > > > Pablo Viojo > > > > > pvi...@gmail.comhttp://pviojo.net > > > > > > ¿Que necesitas?http://needish.com > > > > > > On Thu, Sep 17, 2009 at 3:55 PM, Simon wrote: > > > > > > > un exemple will be appreciated > > > > > > > On Sep 17, 11:14 am, Nectom wrote: > > > > > > > Could do a match based on the Post user_id and the comment > > > > > > > user_id and if > > > > > > > they match set a author class > > > > > > > > On Thu, Sep 17, 2009 at 6:36 PM, Simon > > > > > > > wrote: > > > > > > > > > Hi all is there any way i could Highlight Author's aka admin's > > > > > > > > comments and a reply function on my comment section > > > > > > > > > here is my comment table > > > > > > > > > id > > > > > > > > post_id > > > > > > > > user_id > > > > > > > > comment > > > > > > > > modified > > > > > > > > active > > > > > > > > > i have users groups = admin / users > > > > > > > > > thank you- Hide quoted text - > > > > > > > > - Show quoted text -- Hide quoted text - > > > > > > - Show quoted text -- Hide quoted text - > > > > > - Show quoted text -- Hide quoted text - > > - Show quoted text - --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Highlight Author Comment
Thanks for the reply I'm confuesd here my post table dosent got user_Id user don't have to login and post the only thing the login to comment now here is I give full details User hasMany comments comment belongs to user Post hasMany comments comments belongs to post Now here's my comment table structure Id user_id post_id comment active created here's user table structure id username firstname lastname group = default is user email created here is my post id comment_id content comment_count created modified And I made function in my post controller called function comment() So when some one comment it's like post/comment/1234 I hope this help you slove my problem thank you all On Sep 19, 4:54 am, "j0n4s.h4rtm...@googlemail.com" wrote: > Use cake bake. On the output of cake bakes comments/index.ctp find the > table loop and within that table loop you have to do that comparison > like $post['Post']['user_id'] == $comment['Comment']['author_id'] > > On Sep 18, 3:29 pm, Simon wrote: > > > > > is there sombody help here please thank you im really waiting for > > someone to help here > > > > if($this->$comment['User'[['Group']['admin']){ > > echo''; > > echo $comment['Comment']['comment']; > > echo''; > > > }else{ > > > echo' > > echo $comment['Comment']['comment']; > > echo''; > > > } > > > ?> > > > On Sep 17, 1:24 pm, Simon wrote: > > > > thank you for this can i do it this way correct me if i'm worng > > > > > > if($this->$comment['User'[['Group']['admin']){ > > > echo''; > > > echo $comment['Comment']['comment']; > > > echo'';}else{ > > > > echo' > > > echo $comment['Comment']['comment']; > > > echo'';} > > > > ?> > > > > On Sep 17, 1:00 pm, Pablo Viojo wrote: > > > > > Something like this: > > > > > > > > if ($post['Post']['user_id']==$comment['Comment']['user_id']){ > > > > $commentClass='author';} else { > > > > > $commentClass='non-author';} > > > > > ?> > > > > > > > > > Change your variable names appropiately. > > > > > Regards, > > > > > Pablo Viojo > > > > pvi...@gmail.comhttp://pviojo.net > > > > > ¿Que necesitas?http://needish.com > > > > > On Thu, Sep 17, 2009 at 3:55 PM, Simon wrote: > > > > > > un exemple will be appreciated > > > > > > On Sep 17, 11:14 am, Nectom wrote: > > > > > > Could do a match based on the Post user_id and the comment user_id > > > > > > and if > > > > > > they match set a author class > > > > > > > On Thu, Sep 17, 2009 at 6:36 PM, Simon > > > > > > wrote: > > > > > > > > Hi all is there any way i could Highlight Author's aka admin's > > > > > > > comments and a reply function on my comment section > > > > > > > > here is my comment table > > > > > > > > id > > > > > > > post_id > > > > > > > user_id > > > > > > > comment > > > > > > > modified > > > > > > > active > > > > > > > > i have users groups = admin / users > > > > > > > > thank you- Hide quoted text - > > > > > > > - Show quoted text -- Hide quoted text - > > > > > - Show quoted text -- Hide quoted text - > > > > - Show quoted text - --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Highlight Author Comment
Use cake bake. On the output of cake bakes comments/index.ctp find the table loop and within that table loop you have to do that comparison like $post['Post']['user_id'] == $comment['Comment']['author_id'] On Sep 18, 3:29 pm, Simon wrote: > is there sombody help here please thank you im really waiting for > someone to help here > > if($this->$comment['User'[['Group']['admin']){ > echo''; > echo $comment['Comment']['comment']; > echo''; > > }else{ > > echo' > echo $comment['Comment']['comment']; > echo''; > > } > > ?> > > On Sep 17, 1:24 pm, Simon wrote: > > > thank you for this can i do it this way correct me if i'm worng > > > > if($this->$comment['User'[['Group']['admin']){ > > echo''; > > echo $comment['Comment']['comment']; > > echo'';}else{ > > > echo' > > echo $comment['Comment']['comment']; > > echo'';} > > > ?> > > > On Sep 17, 1:00 pm, Pablo Viojo wrote: > > > > Something like this: > > > > > > if ($post['Post']['user_id']==$comment['Comment']['user_id']){ > > > $commentClass='author';} else { > > > > $commentClass='non-author';} > > > > ?> > > > > > > > Change your variable names appropiately. > > > > Regards, > > > > Pablo Viojo > > > pvi...@gmail.comhttp://pviojo.net > > > > ¿Que necesitas?http://needish.com > > > > On Thu, Sep 17, 2009 at 3:55 PM, Simon wrote: > > > > > un exemple will be appreciated > > > > > On Sep 17, 11:14 am, Nectom wrote: > > > > > Could do a match based on the Post user_id and the comment user_id > > > > > and if > > > > > they match set a author class > > > > > > On Thu, Sep 17, 2009 at 6:36 PM, Simon wrote: > > > > > > > Hi all is there any way i could Highlight Author's aka admin's > > > > > > comments and a reply function on my comment section > > > > > > > here is my comment table > > > > > > > id > > > > > > post_id > > > > > > user_id > > > > > > comment > > > > > > modified > > > > > > active > > > > > > > i have users groups = admin / users > > > > > > > thank you- Hide quoted text - > > > > > > - Show quoted text -- Hide quoted text - > > > > - Show quoted text -- Hide quoted text - > > > - Show quoted text - --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Highlight Author Comment
is there sombody help here please thank you im really waiting for someone to help here $comment['User'[['Group']['admin']){ echo''; echo $comment['Comment']['comment']; echo''; }else{ echo' echo $comment['Comment']['comment']; echo''; } ?> On Sep 17, 1:24 pm, Simon wrote: > thank you for this can i do it this way correct me if i'm worng > > if($this->$comment['User'[['Group']['admin']){ > echo''; > echo $comment['Comment']['comment']; > echo'';}else{ > > echo' > echo $comment['Comment']['comment']; > echo'';} > > ?> > > On Sep 17, 1:00 pm, Pablo Viojo wrote: > > > > > Something like this: > > > > if ($post['Post']['user_id']==$comment['Comment']['user_id']){ > > $commentClass='author';} else { > > > $commentClass='non-author';} > > > ?> > > > > > Change your variable names appropiately. > > > Regards, > > > Pablo Viojo > > pvi...@gmail.comhttp://pviojo.net > > > ¿Que necesitas?http://needish.com > > > On Thu, Sep 17, 2009 at 3:55 PM, Simon wrote: > > > > un exemple will be appreciated > > > > On Sep 17, 11:14 am, Nectom wrote: > > > > Could do a match based on the Post user_id and the comment user_id and > > > > if > > > > they match set a author class > > > > > On Thu, Sep 17, 2009 at 6:36 PM, Simon wrote: > > > > > > Hi all is there any way i could Highlight Author's aka admin's > > > > > comments and a reply function on my comment section > > > > > > here is my comment table > > > > > > id > > > > > post_id > > > > > user_id > > > > > comment > > > > > modified > > > > > active > > > > > > i have users groups = admin / users > > > > > > thank you- Hide quoted text - > > > > > - Show quoted text -- Hide quoted text - > > > - Show quoted text -- Hide quoted text - > > - Show quoted text - --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Highlight Author Comment
thank you for this can i do it this way correct me if i'm worng $comment['User'[['Group']['admin']){ echo''; echo $comment['Comment']['comment']; echo''; }else{ echo' echo $comment['Comment']['comment']; echo''; } ?> On Sep 17, 1:00 pm, Pablo Viojo wrote: > Something like this: > > if ($post['Post']['user_id']==$comment['Comment']['user_id']){ > $commentClass='author';} else { > > $commentClass='non-author';} > > ?> > > > Change your variable names appropiately. > > Regards, > > Pablo Viojo > pvi...@gmail.comhttp://pviojo.net > > ¿Que necesitas?http://needish.com > > > > On Thu, Sep 17, 2009 at 3:55 PM, Simon wrote: > > > un exemple will be appreciated > > > On Sep 17, 11:14 am, Nectom wrote: > > > Could do a match based on the Post user_id and the comment user_id and if > > > they match set a author class > > > > On Thu, Sep 17, 2009 at 6:36 PM, Simon wrote: > > > > > Hi all is there any way i could Highlight Author's aka admin's > > > > comments and a reply function on my comment section > > > > > here is my comment table > > > > > id > > > > post_id > > > > user_id > > > > comment > > > > modified > > > > active > > > > > i have users groups = admin / users > > > > > thank you- Hide quoted text - > > > > - Show quoted text -- Hide quoted text - > > - Show quoted text - --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Highlight Author Comment
Something like this: Change your variable names appropiately. Regards, Pablo Viojo pvi...@gmail.com http://pviojo.net ¿Que necesitas? http://needish.com On Thu, Sep 17, 2009 at 3:55 PM, Simon wrote: > > un exemple will be appreciated > > On Sep 17, 11:14 am, Nectom wrote: > > Could do a match based on the Post user_id and the comment user_id and if > > they match set a author class > > > > > > > > On Thu, Sep 17, 2009 at 6:36 PM, Simon wrote: > > > > > Hi all is there any way i could Highlight Author's aka admin's > > > comments and a reply function on my comment section > > > > > here is my comment table > > > > > id > > > post_id > > > user_id > > > comment > > > modified > > > active > > > > > i have users groups = admin / users > > > > > thank you- Hide quoted text - > > > > - Show quoted text - > > > --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Highlight Author Comment
un exemple will be appreciated On Sep 17, 11:14 am, Nectom wrote: > Could do a match based on the Post user_id and the comment user_id and if > they match set a author class > > > > On Thu, Sep 17, 2009 at 6:36 PM, Simon wrote: > > > Hi all is there any way i could Highlight Author's aka admin's > > comments and a reply function on my comment section > > > here is my comment table > > > id > > post_id > > user_id > > comment > > modified > > active > > > i have users groups = admin / users > > > thank you- Hide quoted text - > > - Show quoted text - --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Highlight Author Comment
Could do a match based on the Post user_id and the comment user_id and if they match set a author class On Thu, Sep 17, 2009 at 6:36 PM, Simon wrote: > > Hi all is there any way i could Highlight Author's aka admin's > comments and a reply function on my comment section > > here is my comment table > > id > post_id > user_id > comment > modified > active > > i have users groups = admin / users > > > thank you > > > > > > > > > --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---