/** * Retrieve the URL of the current post * * @param Fishpig_Wordpress_Model_Post_Comment $comment * @return string */ public function getPostUrl(Fishpig_Wordpress_Model_Post_Comment $comment) { if ($post = $comment->getPost()) { return sprintf('%s#comment-%d', $post->getPermalink(), $comment->getId()); } return '#'; }
/** * Get the HTML of the child comments * * @param Fishpig_Wordpress_Model_Post_Comment $comment * @return string */ public function getChildrenCommentsHtml(Fishpig_Wordpress_Model_Post_Comment $comment) { return $this->getLayout()->createBlock('wordpress/post_view_comments')->setTemplate($this->getTemplate())->setParentId($comment->getId())->setComments($comment->getChildrenComments())->toHtml(); }