I’m trying to figure out what files to update or change so that the buddypress activity stream will recognized short codes. I’m currently using the buddyblog and users are of course able to put a shortcode that displays a video into their post. However; when I go over to the activity screen rather than showing the video I’m provides a link to the post, which makes sense because I wouldn’t want the entire post in the activity stream. However it would be tremedously useful for the user to be able to, simply paste the short code for the “video” into the activity stream… I know that they can simply past the entire url into the stream, however; i need the shortcode in order to support tracking activities. Any ideas would be greatly appreciated.
Hi Carleton,
Welcome to BuddyDev.The problem lies with the BuddyPress. It strips the shortcode while creating excerpt.
Please put the following code in your bp-custom.php
function buddydev_disable_shortcode_filtering_in_activity( $args ) { $args['filter_shortcodes'] =false; return $args; } add_filter( 'bp_after_create_excerpt_parse_args', 'buddydev_disable_shortcode_filtering_in_activity' );
It will allow your users to post shortcodes in the activity stream. Please do let me know if it works for you or not?
Thank you
BrajeshThank you.
I am marking it as a resolved.PS: Please only mark a reply as private if it contains any sensitive information.
Thank you
Brajesh
You must be logged in to reply to this topic.