Skip to content

Shows a row of reaction emojis with counts for the page or post the shortcode sits on. Use it on Pages, in custom post type content and in widget areas, where reactions do not appear on their own.

[bp_reactions]

The shortcode always attaches the reaction to the post that is being displayed. It cannot point at another post.

Attribute Default What it does
id 1 The reaction set number saved with each reaction. It does not change the emojis shown.

No other attribute is read. post_id, post_type and bprs_id are ignored, so [bp_reactions post_id="42"] still shows reactions for the post the shortcode is on.

The emojis come from the content type of the page it sits on. Pages and custom post types use the emojis chosen for WordPress Blog Posts in the Reactions tab. If you change them there, the shortcode follows.

Show reactions at the end of a Page:

[bp_reactions]

Use it in a text or shortcode block inside a widget area. It then attaches to the post or page being viewed.

  • Only logged-in members can react. Visitors see the counts and the names that show on hover, and need to log in to react.
  • The shortcode shows nothing when reactions are off for the post type, or while a password-protected post is still locked.
  • On a Page, the shortcode is the only way reactions appear. Blog posts normally get reactions without it, so you do not need to add it to a blog post.
  • Reactions are saved per member per item. A member who clicks their active emoji again removes the reaction.

Shows the Reactions board anywhere shortcodes run. It takes the same options as the block and the widget.

Attribute Values Default
view emojis, content (most reacted), members emojis
period day, week, month, quarter (90 days), all month
types Comma list of activity, post, forum All
number 1 to 20 5
show_count yes or no yes
title Any text. Empty uses the view’s title Empty

Unknown values fall back to the default.

[bp_reactions_board]
[bp_reactions_board view="members" period="all" number="10"]
[bp_reactions_board view="content" types="forum" period="week" title="Hot in the forums"]

Every view counts public content only. See Reactions Board.

The plugin keeps named reaction sets in the {prefix}bp_reactions_shortcodes table. A fresh install creates them in this order:

ID Name
1 Posts Reaction
2 Activity Reaction
3 Activity Comment Reaction
4 bbPress Topic Reactions
5 bbPress Reply Reactions

ID 1 is the Posts set, and it is the number [bp_reactions] uses when you give no id. Numbers on a site upgraded from an older version can differ.

The set number is saved with each reaction as bprs_id, but which emojis appear is decided by the content type’s settings, not by the set. Activity reactions are saved with bprs_id 1, activity comments 2, forum topics 3 and forum replies 4, whatever the table above says. Blog posts and the shortcode use the set’s own ID. See Database Schema.