Notice: These forums are now retired and closed. For active support, please Submit a Ticket or visit our official WordPress.org community pages.
Kadence Theme | Kadence Blocks | Starter Templates | WooCommerce Email Designer | Ascend | Virtue | Pinnacle

Changing virtue_post_comments to embed comments in tabs

Home / Forums / Virtue Theme / Changing virtue_post_comments to embed comments in tabs

This topic is: Resolved
[Resolved]
Posted in: Virtue Theme
June 8, 2018 at 9:51 am

Hello,

I’m trying to edit the virtue_post_comments functions to embed comments inside a (Virtue) tab, next to a tab containing BP activity stream.
I created a child theme, and edited lib/template_hooks/posts.php so that
add_action( 'kadence_single_post_after', 'virtue_post_comments', 40 );
function virtue_post_comments() {
echo "Mettre les questions ici !";
echo do_shortcode ('[tabs][tab title="Les questions des Grands Explorateurs" start=open]'.'[activity-stream]'.'[/tab][tab title="Les réactions des explorateurs en herbe"]'.comments_template('/templates/comments.php').'[/tab][/tabs]');
}

instead of
add_action( 'kadence_single_post_after', 'virtue_post_comments', 40 );
function virtue_post_comments() {
comments_template('/templates/comments.php');
}

It kind of works… The activity stream does show up in the first tab, but the actual comments do not show up inside the 2ntab.. instead they show up above the tabs.
Any idea why? Thanks for your support!

  • The forum ‘Virtue Theme’ is closed to new topics and replies.