BuddyDev

Search

[Resolved] Custom Background for User Profile

  • Participant
    Level: Master
    Posts: 413
    Venutius on #19165

    Hi Brajesh,

    I hope you don’t mind but I’ve forked another of your plugins – Custom Profile Backgrounds. I’ve created a sister plugin called BP Custom Headers for User Profiles.

    Together with these, my new BP User Widgets plugin (when I release it) go a long way toowards deliering a completely user customizable BP Profile, which is something I’ve wanted for a long time.

    I’ve a couple of suggestions regarding Custom Background:

    Line 93 in bp-custom-background-for-user-profile.php, it mentions a page title of Profile Photo, ths should really be something like Change Background Image.

    Also, as a feature enhancement I’d like to suggest you add an admin bar menu item fr it, you could add:

    function bpcbg_admin_bar_add() {
    
    	global $wp_admin_bar, $bp;
     
    	if ( !bp_use_wp_admin_bar() || defined( 'DOING_AJAX' ) )
    		return;
     
    	$user_domain = bp_loggedin_user_domain();
    	$item_link = trailingslashit( $user_domain . '/profile/change-bg' );
     
    	// add submenu item
    	$wp_admin_bar->add_menu( array(
    		'parent'  => 'my-account-xprofile',
    		'id'      => 'my-account-xprofile-changebg',
    		'title'   => __( 'Change Background Image', 'bp-custom-backgrund-for-user-profile' ),
    		'href'    => trailingslashit( $item_link ),
    	) ); 
    }
    
    add_action( 'bp_setup_admin_bar', 'bpcbg_admin_bar_add', 300 );

    Though I’m sure you’d have a much better way of achieving the same end.

  • Keymaster
    (BuddyDev Team)
    Posts: 24593
    Brajesh Singh on #19178

    Hi George,

    You are welcome to fork the plugin.

    We stopped working on any advance version of this plugin as almost all themes needed additional support and the support burden was too much to justify adding extra features to it.

    Thank you for the suggestion about adding adminbar link. Your code is perfect. I will include it in the next update.

    Regards
    Brajesh

  • Participant
    Level: Master
    Posts: 413
    Venutius on #19196

    Thanks Brajesh

The topic ‘ [Resolved] Custom Background for User Profile’ is closed to new replies.

This topic is: resolved