Hi,
this code works for me
//Remove the custom where clause before the calendar query is executed
function hubbubart_calendar_remove_posts_where() {
remove_filter( ‘posts_where’, ‘wpfc_temp_filter_where’ );
}
add_action(‘wpfc_before_wp_query’, ‘hubbubart_calendar_remove_posts_where’, 10);
//Override the item timestamp
function change_calendar_item_date($item, $post) {
$debut = date(“Y-m-d\TH:i:s”, strtotime(get_field(‘debut’, $post->ID) .’ ‘ .’00:00:00’));
$fin = date(“Y-m-d\TH:i:s”, strtotime(get_field(‘fin’, $post->ID) .’ ‘ .’24:00:00’));
$item[‘start’] = $debut;
$item[‘end’] = $fin;
return $item;
}
add_filter(‘wpfc_ajax_post’, ‘change_calendar_item_date’, 10, 2);