By Benoit Gonneville Damme on Wednesday, 10 February 2016
Posted in General Issues
Replies 1
Likes 0
Views 1.1K
Votes 0
Hi,

This is the same question than this post: http://stackideas.com/forums/how-to-add-eb-image-to-komento-s-es-stream-item. I wanted to add the following question to the thread but the discussion was locked.

I know this is customization, so I am not asking for direct help, but I am just trying to figure out with the small knowledge I have, how to do what I want to do. Sorry for bothering :s

In the previous discussion, we assigned variables


$this->set('image', $comment->extension->_item->getImage());
$this->set('permalink', $comment->extension->_item->getPermalink());


To be able to call in content.php
<?php echo $image; ?>


I am trying to add the original EB post's category and content to the stream item and I can't find the correct expression to use to call and assigned those variables...

I tried this:


$this->set(title, $comment->extension->_item->getCategory());
$this->set('content', $comment->extension->_item->getContent());


or this


$this->set('category', $item->category);
$this->set('content', $item->content);


and this in the content.php
<?php echo $category; ?>


None of these work. I have just been able to call the title with
<?php echo $comment->contenttitle; ?>


Again, I know this is more a customization then a issue, but if you find time to indicate me the correct expression (or a documentation I could read to understand it myself), I would greatly appreciated.

Thank you for considering helping me out!

Cheers.

B.
I would suggest you take a look at the comment object and based on the comment object, get the blog post's id. With the blog post's id, you could retrieve EasyBlog's post object like this,

·
Thursday, 11 February 2016 01:22
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post