Support » Plugin: BuddyPress Profile Progression » [Plugin: BuddyPress Profile Progression] Buddypress 1.5 Compatibility

  • The plugin can be updated to be compatible with 1.5 as follows:

    Line 14: before foreach($group->fields as $key=>$field) { add
    if (count($group->fields) > 0 ) {
    Line 24: add }

    The plugin can also be added to so that if a user clicks on their own progress it takes them to the profile edit page OR if they click on another users profile progress it takes them to that users profile.

    around line: 62 after $percent_width=($percent/100)*$image['width']; add

    `//if user is looking at own profile then present link to edit own profile
    //otherwise present link to view other users profile.
    if ($bp->displayed_user->id == $bp->loggedin_user->id) {
    $view_url = $bp->loggedin_user->domain . “profile/edit/group/1”;
    } else {
    $view_url = “profile”;
    }`
    change the code from around line 74: starts with <div class="bppp-stat"> to

    <div class="bppp-stat">
    		<a href="<?=$view_url;?>" title="<?php echo $image['alt'];?>">
    		<?php echo $image['msg_before'];?>
            </a>
    		<div class="bppp-stat-container" style="width:<?php echo $image['width'];?>px">
    			<div class="bppp-stat-bar" style="width:<?php echo $percent_width;?>px">
    			<a href="<?=$view_url;?>" title="<?php echo $image['alt'];?>">
    			<img alt="<?php echo $image['alt'];?>" src="<?php echo $image['url'];?>"/>
    			</a>
    			</div>
    		</div>

    http://wordpress.org/extend/plugins/buddypress-profile-progression/

Viewing 8 replies - 1 through 8 (of 8 total)
  • It’s not working for me! I use BP 1.5.2 & WPMU 3.3.1

    Warning:

    trim() expects parameter 1 to be string, array given in …\wp-content\plugins\buddypress-profile-progression\includes\bppp-core.php on line 32

    Line 32:

    $profile_value = trim(bp_get_profile_field_data( $field_args ));

    Bummer, I wish this was a default BuddyPress feature.

    cwhittl

    (@cwhittl)

    change line 31 to $profile_value = trim(bp_get_profile_field_data( $field['id'],$user_id ));

    Thanks, no more errors, but on members profile the progression block is completely white.

    Yes, mine too: completely white?!

    plugins/buddypress-profile-progression/includes/bppp-core.php on line 31

    http://buddygalaxy.com

    Hi, Im using buddypress Version 1.6.1 I tried the code above but doesn’t work. can you please tell me what to do ? thx

    Hi guys, this is my first time posting here, yesterday i installed buddypress and profile progression and all these stuff…

    I’m using,
    Buddypress Version 1.6.1
    WordPress Version 3.4.1
    BuddyPress Profile Progression Version 0.1

    And i’ve already tried all of the above for errors….

    So, when i was building the profile fields after a step, i got this error

    trim() expects parameter 1 to be string, array given in …\wp-content\plugins\buddypress-profile-progression\includes\bppp-core.php on line 31

    I was getting this error every time, that i was putting a field (in profile) which was different from a text field.

    For instance, if i put a select box i will get the above error.

    And that’s normal for the functions logic…

    Solution…

    In order to overcome this problem go to
    “wp-content\plugins\buddypress-profile-progression\includes\bppp-core.php”

    and find this line

    $profile_value = trim(bp_get_profile_field_data( $field_args ));

    and just replace it with this

    $profile_value = (bp_get_profile_field_data( $field_args ));

    The trim function at this point, is the reason for the error.

    Normally you will not get any error, and the progression bar will work just fine.

    Let me know if sth else happens.

    Although I have blank fields, on all members profiles I get the same results: “This profile is 100% complete” with a full view of “progress_bar.png” image.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘[Plugin: BuddyPress Profile Progression] Buddypress 1.5 Compatibility’ is closed to new replies.