Created
March 12, 2018 18:51
-
-
Save cliffordp/5e7d6c6ca9dd91d1bf2b8090e8e26333 to your computer and use it in GitHub Desktop.
Events Calendar PRO: Output Additional Fields meta information on Day View.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Events Calendar PRO: Output Additional Fields meta information on Day View. | |
* | |
* @link https://gist.github.com/cliffordp/5e7d6c6ca9dd91d1bf2b8090e8e26333 | |
* @link https://theeventscalendar.com/support/forums/topic/get-extra-fields-in-day-view/ | |
*/ | |
function cliff_tec_pro_additional_fields_on_day_view() { | |
if ( | |
! function_exists( 'tribe_is_day' ) | |
|| ! tribe_is_day() | |
|| ! method_exists( 'Tribe__Events__Pro__Single_Event_Meta', 'additional_fields' ) | |
) { | |
return; | |
} | |
$pro_single_meta = new Tribe__Events__Pro__Single_Event_Meta; | |
$pro_single_meta->additional_fields(); | |
} | |
add_action( 'tribe_events_after_the_content', 'cliff_tec_pro_additional_fields_on_day_view', 50 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment