BuddyBoss Home – Web › Support Forums › General › BuddyPress (general issues) › How to change the text as per the user gender?
Tagged: activity stream, Gender, Her, His
- This topic has 6 replies, 3 contibutors, and was last updated 9 years, 8 months ago by Anonymous.
Question
March 11, 2015 at 1:45 am #37139@benworxhi,
the issue is when user change the profile or update the profile then it always show that e.g
Marijke changed his profile picture. in this case Marijke is female and text should be like Marijke changed her profile picture.but always shows his
so how to fix this problem .TY
Answers
March 14, 2015 at 7:41 am #37296@style960@benworx What version of Buddypress are you using? I have 2.2.1 with no edited translations, and I see “Ben changed their profile picture”…
March 15, 2015 at 11:34 pm #37394@benworxHi Paul ,
The version of Buddypress i am using is 2.2.1 . and what i seen is Karen Anne Bakker changed his profile picture (But is should be like Karen Anne Bakker changed her profile picture)March 18, 2015 at 10:12 am #37515@benworxHi Paul,
The gender setting does not seem available in the Buddyboss profile.
Gender is a standard function from Buddypress. Is there a method to implement it in to the theme and wall?
Thanx!
March 18, 2015 at 10:20 am #37516@style960@benworx I don’t use BB Wall so I can’t advise there. Have you tried disabling that to see if your grammar issue is still there? I don’t see it on a standard Buddypress install with BB or Boss installed.
March 18, 2015 at 10:42 am #37517@benworxThanx Paul,
I’ll start asking these questions in the moderated forum for the Buddyboss wall..
It is in the wall that the gender issue appears:
Example: Sarah update his profile picture…
Thanx for your help!
Ben
March 20, 2015 at 2:37 pm #37616@
AnonymousHello Ben, Gender is not the core field for the Buddypress or WordPress.
it is site admin who creates X-profile fields on the basis of his requirements.Add this code in bp-custom.php or child themes functions.php
and create a Xprofile Field with name : Gender
with option Male and FemaleIt is just a conditional check for print updated message.
function boss_activity_change_avatar( $entry, $user_id ) { $gender = bp_get_profile_field_data( 'field=Gender&user_id=' . $user_id ); if ( $gender == 'Male' ) { $entry = sprintf( __( '%s updated his profile picture', 'buddypress' ), $userlink ); } else if ( $gender == 'Female' ) { $entry = sprintf( __( '%s updated her profile picture', 'buddypress' ), $userlink ); } else { } return $entry; } add_filter( 'bp_xprofile_new_avatar_action', 'boss_activity_change_avatar', 10, 2 );
Regards
Varun Dubey
- The question ‘How to change the text as per the user gender?’ is closed to new replies.