Buddypress Profile Cover Image not working

I’m working on a local install.

Trying to give buddypress members the ability to set a profile cover image.

With X theme enabled the url for the upload section results in a 404

SITEURL/members/USERNAME/profile/change-cover-image/

Whereas with twentyninteen the page loads correctly

Just in case anyone else is having this problem, I’ve worked it out.

The issue is X’s setup for buddypress disables cover images for profiles (In \themes\x\framework\functions\plugins/buddypress.php)

So you need to add this to your child theme’s functions.php:

 // Force X theme to enable cover images for BP members
function remove_parent_filters(){ 
	remove_filter( 'bp_is_profile_cover_image_active', '__return_false' );
}
add_action( 'after_setup_theme', 'remove_parent_filters' );

However I still can’t get comments in the activity feed to work in X :joy:

Works in twentyninteen just fine

Looks like I solved the comment issue too.

Whatever was supposed to be changing the comment form from display:none to display:block when the comment button is pressed doesn’t fire.

So I put together this bit of jQuery

//Show Me The Comment Form
  jQuery('.acomment-reply').click(function(){
   var buttonId = jQuery(this).attr('id');
   var cutter = '#ac-form-'+buttonId.replace('acomment-comment-',''); 
   jQuery(cutter).css('display','block');
   
})

Glad it’s working now and thanks for sharing! Cheers!

The above jQuery wasn’t working for replying to comments on activity, so I wrote some for that too.

It’s not the neatest and I’m sure someone could do a cleaner job, but this’ll work for the time being:

// Main Comment Box Show-er
  jQuery('.activity-content .acomment-reply.bp-primary-action').click(function(){
   var buttonId = jQuery(this).attr('id');
   var cutter = '#ac-form-'+buttonId.replace('acomment-comment-','');
  var inputter = '#ac-input-'+buttonId.replace('acomment-comment-','');
   jQuery(cutter).css('display','flex');
    jQuery(inputter).focus();
   
})
// Comment On Another Comment Box Show-er
 jQuery('.activity-meta.action .acomment-reply.bp-primary-action').click(function(){
   var buttonId2 = jQuery(this).attr('id');
   var cutter1 = buttonId2.replace('acomment-reply-',''); 
   var cutter2 = cutter1.replace('-from-\d+','');
   var cutter3 = '#ac-form-'+cutter2;
    var suffix = this.id.match(/\d+/);
   var nucutter = '#ac-form-'+suffix;
   jQuery(nucutter).css('display','flex');
    var inputter = '#ac-input-'+suffix;
    jQuery(inputter).focus();
  
})

Hello @waterbarry,

We are just glad that you have figured it out a way to correct the said issue.
Thanks for letting us know!

Best Regards.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.