Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function event_list_donation_marker( $cost, $post_id ) {
- // Only add the donation marker in list view
- if ( ! tribe_is_list_view() ) return $cost;
- $fields = tribe_get_custom_fields( $post_id );
- if ( ! empty( $fields['Donation'] ) && 'Yes' === $fields['Donation'] )
- $cost .= ' BY DONATION ';
- return $cost;
- }
- add_filter( 'tribe_get_cost', 'event_list_donation_marker', 100, 2 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement