[buddypress-dev] Profile pic 2 admins...

Andreas Hanfelt andreas at hanfelt.se
Mon Jun 30 20:10:25 GMT 2008


If you have 2 admins you will get no profile pic..
I found some code and merged it with buddypress to get atleast one  
admin profile pic to show up..

this code can be pasted in optionsbar.php in the theme

			<?php // bp_get_options_avatar() ?>
			<?php
			global $wpdb, $blog_id, $wpmuBaseTablePrefix;
         	
			$blogownerid = $wpdb->get_var("SELECT post_author FROM " .  
$wpmuBaseTablePrefix . $blog_id . "_posts");
			$bp_profile_pix = xprofile_get_avatar($blogownerid, $version = 1);
		 echo $bp_profile_pix;

It replaces the function above bp_get_options_avatar()

Im no developer but i can understand some code i see. Maybe this is  
useful for the developers of buddypress...

Cheers!
Andreas Hanfelt


More information about the buddypress-dev mailing list