at the moment this requires custom coding on your part since this is not available by default and not yet integrated with Custom Post Type UI plugin however maybe you can get some idea from this custom snippet
// load events with grades tax
function my_em_grades_event_load($EM_Event){
global $wpdb;
$EM_Event->grades = $wpdb->get_col("SELECT term_taxonomy_id FROM $wpdb->term_relationships WHERE object_id='{$EM_Event->post_id}'", 0 );
}
add_action('em_event','my_em_grades_event_load',1,1);
// get events with grades term
add_filter('em_events_get','my_em_grades_events_get',1,2);
function my_em_grades_events_get($events, $args){
if( !empty($args['grade']) ){
foreach($events as $event_key => $EM_Event){
if( !in_array($args['grade'],$EM_Event->grades) ){
unset($events[$event_key]);
}
}
}
return $events;
}
// add taxonomy to search
add_filter('em_events_get_default_search','my_em_grades_get_default_search',1,2);
function my_em_grades_get_default_search($searches, $array){
if( !empty($array['grade']) ){
$searches['grade'] = $array['grade'];
}
return $searches;
}
Ok, thanks – not what I want to hear, this makes it more difficult for now. But thanks for the info. I think for now we’ll try to work around the issue without custom coding. That said, I may be back with further questions if we decide to go this route. Thanks!
Actually, I realize I do have a question. You mention that this is not possible through CPTUI for now, but actually wouldn’t it be a capability on the Event Manager Plugin side?
On other pages on this same site, I’m calling in custom posts using custom taxonomies just fine through the Custom Content Shortcode plugin. The issue is that I want to be able to do the same for the events pages using the Events Manager plugin, since CCS can’t distinguish between “past” and “future” posts as far as I can tell.
Here’s what I’m doing on other pages through the CCS plugin.
[loop type="training" taxonomy="training-type" term="immersion"]
[field title-link]
[/loop]
Obviously the specifics are going to be different when using the EM plugin to call the event list, but hopefully there’d be a way to call the taxonomy & taxonomy term when calling the event_list.
Thanks again!