Please or Register to create posts and topics.

Insert own shortcode at the end of each post

PreviousPage 2 of 2

Can you try if this is working?

function my_rating($authorID, $postID) {
    echo do_shortcode('[rating_form id="4" post_id="forum_post_'.$postID.'"]');
}

add_action('asgarosforum_after_post_message', 'my_rating', 10, 2);

 

If you want to support the development of Asgaros Forum, you can leave a good review or donate. Thank you very much!

Hi Asgaros,

I regret, no. Tested with some Voting-Plugins (all claiming to work within bbPress and/or with a given ID).

Regards, Andreas

Quote from Andreas on September 15, 2017, 11:07 am

Hi Asgaros,

I regret, no. Tested with some Voting-Plugins (all claiming to work within bbPress and/or with a given ID).

Regards, Andreas

Is it verfified, that the could in the postings above (by Asgaros) SHOULD work, if the voting-plugin is capable to manage the passed variables?

So I´d test some more voting-plugins…

Regards, Andreas

I am not sure, I dont know this plugin. Maybe it only can use numeric values and you can try to remove the forum_ post_ prefix for the ID.

If you want to support the development of Asgaros Forum, you can leave a good review or donate. Thank you very much!

Thanks for your help, guys. Solution is sooo easy:

 

echo do_shortcode(‘[rating_form id=”4″ custom_id=”‘.$postID.'”]’);

instead of

echo do_shortcode(‘[rating_form id=”4″ post_id=”‘.$postID.'”]’);

 

Thanks again!

Regards, Michael

I am happy to hear that it is working now! 🙂

If you want to support the development of Asgaros Forum, you can leave a good review or donate. Thank you very much!
PreviousPage 2 of 2