Advertisement
Search the Community
Showing results for tags 'member'.
-
Hello. I need 4 membergroups icons. Groups: 1) Admin 2) Global Mod 3) Mod 4) VIP Colors i need: Black and the text inside bold with hex: #b8d24c Can anyone do that for me? Thanx
-
hi hello iam priya jain how r u
-
Hello all I'm a new member from Philippines! Hope to find a good community here!
-
Hello, my name is Roylan Mesada. and I'm a Internet Article Writer and a Internet Advertising Expert. I'm a graduate from SNHU with a degree in Creative Writing and Business Administration. I kinda got into nulled or cracked software when phpbb 3 was beginning to be a pain in the arse to code and my members quit on the site. I hope this community will be a place for me to learn more about nulled software, how to nullfiy it, and be general part of this community.
- 4 replies
-
- TheMagician
- Internet
-
(and 2 more)
Tagged with:
-
Using following function you can get a specified user's gender specified variables. For example... echo "Your friend updated " . IPSMember::fetchGenderCall( IPSMember::load( 1 ) ) . " status."; Will output... (if target user is male) Or... (if target user is female) In a shell... [*]This function is to be placed on your ipsMember.php (IPB 3.2.x+) or core.php (older than IPB 3.1.x) [*]This function has two parameters as follows... [*]$memberData - array - Array of data preloaded of the target user [*]$uppercase - boolean - In case if you want to use that on first of a sentence it will uppercase the first letter (e.g. "His topic just got a reply") The code... Open adminsourcesbaseipsMember.php and find fetchSeoName() function. Add this function after that. (You can place this function anywhere, but be sure to put it inside ipsMember class and outside any internal function). /** * Fetches Gender Relative Call * * @access public * @param array Member data * @param boolean Uppercase word's first letter? * @return string Gender */static public function fetchGenderCall( $memberData, $uppercase=false ){ $researchMember = $memberData; if ( ! is_array( $researchMember ) OR ! $researchMember['member_id'] ) { $researchMember = $this->memberData; } if( $researchMember['pp_gender'] == 'm' ) { return ( $uppercase ) ? ucwords( 'his' ) : 'his'; } elseif( $researchMember['pp_gender'] == 'f' ) { return ( $uppercase ) ? ucwords( 'her' ) : 'her'; } // Because mostly men browsing community forums, isn't it? elseif( $researchMember['pp_gender'] == 'u' OR !$researchMember['pp_gender'] ) { return ( $uppercase ) ? ucwords( 'his' ) : 'his'; }} How to call that? A few examples with outputs are below... ("1" indicates the user ID of the targeted user) "Your friend updated " . IPSMember::fetchGenderCall( IPSMember::load( 1 ) ) . " status."; IPSMember::fetchGenderCall( IPSMember::load( 1 ), true ) . " status has been commented."; Thanks for using best forum software ever, Invision Power Board! Keep up the great work!