Skip to:
Content
Pages
Categories
Search
Top
Bottom

Reply To: Change the order of the date of the profile buddypress2.0.1

@danbp

Participant

standard display of birthdate has become a DD-MM-YY.
This is because you set it like this in wordpress !

Add this snippet to your child theme functions.php or into bp-custom.php
(tested with 2.0.1 and Twenty Thirteen)

// modify the date (format) output on xprofile
function nanopass_date_format_on_profile ($time) {
	global $bp;
	if ( bp_is_active( 'xprofile' ) || bp_is_profile_component() || bp_is_member()  ) {	
		$time = current_time ('Y-m-d'); // date format - See https://codex.wordpress.org/Formatting_Date_and_Time
	}
	return $time;
}
add_action ( 'bp_format_time', 'nanopass_date_format_on_profile', 1 );

Give feedback if it works for you.

Skip to toolbar