@talli22
The “Birthday” display in the Player Details is actually being rendered from the Published Date that is used for the player post type.
So – at this time you would not be able to leave this as optional.
Perhaps SportPress will improve on this feature.
Until then – you could :
– create a player with a “fake birthday” such as January 01, 1900
– use the template to not print the date is the birthday string is equal to January 01, 1900
This is just a quick and dirty way to implement, not great practice.
Just do something like this :
– copy the player-details.php file from here :
/wp-content/plugins/sportspress/templates/player-details.php
to here :
/wp-content/themes/<child-theme>/sportspress/player-details.php
on Line 128 change this :
foreach( $data as $label => $value ):
$output .= ‘<dt>’ . $label . ‘</dt><dd>’ . $value . ‘</dd>’;
endforeach;
to this :
foreach( $data as $label => $value ) {
if ($value == ‘January 1, 1900’) { $value=”; }
$output .= ‘<dt>’ . $label . ‘</dt><dd>’ . $value . ‘</dd>’;
}